Allows to export code writing a string. More...
#include <export_statement_string.hpp>
Public Member Functions | |
virtual ExportStatement * | clone () const |
virtual returnValue | exportCode (std::ostream &stream, const std::string &_realString="real_t", const std::string &_intString="int", int _precision=16) const |
ExportStatementString (const std::string &_statementString=std::string()) | |
virtual | ~ExportStatementString () |
Public Member Functions inherited from ExportStatement | |
virtual ExportStatement & | acquire (ExportIndex &) |
virtual ExportStatement & | allocate (MemoryAllocatorPtr) |
virtual returnValue | exportDataDeclaration (std::ostream &stream, const std::string &_realString="real_t", const std::string &_intString="int", int _precision=16) const |
ExportStatement () | |
ExportStatement (const ExportStatement &arg) | |
ExportStatement & | operator= (const ExportStatement &arg) |
virtual ExportStatement & | release (const ExportIndex &) |
virtual | ~ExportStatement () |
Protected Attributes | |
std::string | statementString |
Additional Inherited Members | |
Public Types inherited from ExportStatement | |
typedef std::shared_ptr< MemoryAllocator > | MemoryAllocatorPtr |
typedef std::shared_ptr< ExportStatement > | StatementPtr |
typedef std::vector< StatementPtr > | StatementPtrArray |
Static Public Attributes inherited from ExportStatement | |
static std::string | fcnPrefix = "acado" |
static std::string | varPrefix = "ACADO" |
Allows to export code writing a string.
The class ExportStatementstd::string allows to export code writing a string.
\author Hans Joachim Ferreau, Boris Houska
Definition at line 54 of file export_statement_string.hpp.
BEGIN_NAMESPACE_ACADO ExportStatementString::ExportStatementString | ( | const std::string & | _statementString = std::string() | ) |
Default constructor which optionally takes the string to be exported.
@param[in] _statementstd::string std::string to be exported.
Definition at line 44 of file export_statement_string.cpp.
|
virtual |
Destructor.
Definition at line 51 of file export_statement_string.cpp.
|
virtual |
Clone constructor (deep copy).
\return Pointer to cloned object.
Implements ExportStatement.
Definition at line 56 of file export_statement_string.cpp.
|
virtual |
Exports source code of the string into given file. Its appearance can can be adjusted by various options.
@param[in] stream Name of file to be used to export string. @param[in] _realSstring std::string to be used to declare real variables. @param[in] _intString std::string to be used to declare integer variables. @param[in] _precision Number of digits to be used for exporting real values. \return SUCCESSFUL_RETURN
Implements ExportStatement.
Definition at line 62 of file export_statement_string.cpp.
|
protected |
std::string to be exported.
Definition at line 97 of file export_statement_string.hpp.