本文整理汇总了C++中Species::toSBML方法的典型用法代码示例。如果您正苦于以下问题:C++ Species::toSBML方法的具体用法?C++ Species::toSBML怎么用?C++ Species::toSBML使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Species
的用法示例。
在下文中一共展示了Species::toSBML方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: equals
END_TEST
START_TEST (test_WriteL3SBML_Species_conversionFactor)
{
const char* expected =
"<species id=\"Ca2\" compartment=\"cell\""
" hasOnlySubstanceUnits=\"false\""
" boundaryCondition=\"true\" constant=\"true\""
" conversionFactor=\"p\"/>";
const char* expected1 =
"<species id=\"Ca2\" compartment=\"cell\""
" hasOnlySubstanceUnits=\"false\""
" boundaryCondition=\"true\" constant=\"true\"/>";
Species *s = D->createModel()->createSpecies();
s->setId("Ca2");
s->setCompartment("cell");
s->setBoundaryCondition(true);
s->setHasOnlySubstanceUnits(false);
s->setConstant(true);
s->setConversionFactor("p");
char* sbml = s->toSBML();
fail_unless( equals(expected, sbml) );
safe_free(sbml);
s->unsetConversionFactor();
sbml = s->toSBML();
fail_unless( equals(expected1, sbml) );
safe_free(sbml);
}