CppADCodeGen
2.3.0
A C++ Algorithmic Differentiation Package with Source Code Generation
|
Public Member Functions | |
DynamicModelLibraryProcessor (ModelLibraryCSourceGen< Base > &modelLibGen, const std::string &libraryName="cppad_cg_model") | |
const std::string & | getLibraryName () const |
void | setLibraryName (const std::string &libraryName) |
const std::string * | getCustomLibraryExtension () const |
void | setCustomLibraryExtension (const std::string &libraryExtension) |
void | removeCustomLibraryExtension () |
std::map< std::string, std::string > & | getOptions () |
const std::map< std::string, std::string > & | getOptions () const |
std::unique_ptr< DynamicLib< Base > > | createDynamicLibrary (CCompiler< Base > &compiler, bool loadLib=true) |
void | createStaticLibrary (CCompiler< Base > &compiler, Archiver &ar, bool posIndepCode) |
Protected Member Functions | |
virtual std::unique_ptr< DynamicLib< Base > > | loadDynamicLibrary () |
const std::map< std::string, std::string > & | getLibrarySources () |
const std::map< std::string, std::string > & | getSources (ModelCSourceGen< Base > &model) |
Protected Attributes | |
std::string | _libraryName |
const std::string * | _customLibExtension |
std::map< std::string, std::string > | _options |
ModelLibraryCSourceGen< Base > * | modelLibraryHelper_ |
Useful class for generating source code for the creation of a dynamic library.
Definition at line 28 of file dynamic_library_processor.hpp.
|
inline |
Creates a new helper class for the generation of dynamic libraries using the C language.
modelLibGen | |
libraryName | The path of the dynamic library to be created (without the extension) |
Definition at line 52 of file dynamic_library_processor.hpp.
|
inline |
Compiles all models and generates a dynamic library.
compiler | The compiler used to compile the sources and create the dynamic library |
loadLib | Whether or not to load the dynamic library |
Definition at line 118 of file dynamic_library_processor.hpp.
|
inline |
Compiles all models and generates a static library.
compiler | The compiler used to compile the sources |
ar | The archiver used to assemble the compiled source into a static library |
posIndepCode | Whether or not to compile the source with position independent code (static libraries typically do not use this feature) |
Definition at line 174 of file dynamic_library_processor.hpp.
|
inline |
Provides a custom library extension defined by the user
Definition at line 74 of file dynamic_library_processor.hpp.
|
inline |
System dependent custom options
Definition at line 99 of file dynamic_library_processor.hpp.
|
inline |
System dependent custom options
Definition at line 106 of file dynamic_library_processor.hpp.
|
inline |
Resets the library extension to the default
Definition at line 91 of file dynamic_library_processor.hpp.
|
inline |
Defines a custom extension for the library that will be created
libraryExtension | the custom extension name |
Definition at line 83 of file dynamic_library_processor.hpp.
|
protected |
a custom extension for the dynamic library (e.g. ".so.1")
Definition at line 37 of file dynamic_library_processor.hpp.
Referenced by CppAD::cg::DynamicModelLibraryProcessor< Base >::createDynamicLibrary(), CppAD::cg::DynamicModelLibraryProcessor< Base >::createStaticLibrary(), CppAD::cg::DynamicModelLibraryProcessor< Base >::getCustomLibraryExtension(), CppAD::cg::DynamicModelLibraryProcessor< Base >::removeCustomLibraryExtension(), and CppAD::cg::DynamicModelLibraryProcessor< Base >::setCustomLibraryExtension().
|
protected |
the path of the dynamic library to be created
Definition at line 33 of file dynamic_library_processor.hpp.
Referenced by CppAD::cg::DynamicModelLibraryProcessor< Base >::createDynamicLibrary(), CppAD::cg::DynamicModelLibraryProcessor< Base >::createStaticLibrary(), and CppAD::cg::DynamicModelLibraryProcessor< Base >::DynamicModelLibraryProcessor().
|
protected |
System dependent custom options
Definition at line 41 of file dynamic_library_processor.hpp.
Referenced by CppAD::cg::DynamicModelLibraryProcessor< Base >::getOptions().