List of all members | Public Member Functions
casadi::CodeGenerator Class Reference

Helper class for C code generation. More...

#include <code_generator.hpp>

Detailed Description

Author
Joel Andersson
Date
2016

Extra doc: https://github.com/casadi/casadi/wiki/L_ru

Definition at line 43 of file code_generator.hpp.

Public Member Functions

 CodeGenerator (const std::string &name, const Dict &opts=Dict())
 Constructor. More...
 
void add (const Function &f, bool with_jac_sparsity=false)
 Add a function (name generated) More...
 
std::string dump ()
 Generate a file, return code as string. More...
 
std::string generate (const std::string &prefix="")
 Generate file(s) More...
 
void add_include (const std::string &new_include, bool relative_path=false, const std::string &use_ifdef=std::string())
 Add an include file optionally using a relative path "..." instead of an absolute path <...> More...
 

Constructor & Destructor Documentation

◆ CodeGenerator()

casadi::CodeGenerator::CodeGenerator ( const std::string &  name,
const Dict opts = Dict() 
)

Member Function Documentation

◆ add()

void casadi::CodeGenerator::add ( const Function f,
bool  with_jac_sparsity = false 
)

◆ add_include()

void casadi::CodeGenerator::add_include ( const std::string &  new_include,
bool  relative_path = false,
const std::string &  use_ifdef = std::string() 
)

◆ dump()

std::string casadi::CodeGenerator::dump ( )

◆ generate()

std::string casadi::CodeGenerator::generate ( const std::string &  prefix = "")

The "prefix" argument will be prepended to the generated files and may be a directory or a file prefix. returns the filename

Extra doc: https://github.com/casadi/casadi/wiki/L_rv


The documentation for this class was generated from the following file: