COPASI API  4.40.278
CSEDMLExporter.cpp File Reference

Macros

#define SEDML_SET_ID(element, arguments)
 

Functions

std::string createUniqueModelFileName (const std::string &dir, const std::string &baseName, const std::string &extension=".xml")
 

Macro Definition Documentation

◆ SEDML_SET_ID

#define SEDML_SET_ID (   element,
  arguments 
)
Value:
{\
std::ostringstream idStream; idStream << arguments;\
std::string pVarId = idStream.str();\
int count = 1;\
while (mGeneratedIds.find(pVarId) != mGeneratedIds.end())\
{\
pVarId = SEDMLUtils::getNextId(idStream.str(), ++count);\
}\
mGeneratedIds.insert(pVarId);\
element->setId(pVarId);\
}
static std::string getNextId(const std::string &base, int count)
Definition: SEDMLUtils.cpp:495

Export the model and Task to SEDML. The SEDML document is returned as a string and SBML model is copied to sbmldocument parameter. In case of an error, an empty string is returned.

Function Documentation

◆ createUniqueModelFileName()

std::string createUniqueModelFileName ( const std::string &  dir,
const std::string &  baseName,
const std::string &  extension = ".xml" 
)