本文整理汇总了C++中Objective::isSetType方法的典型用法代码示例。如果您正苦于以下问题:C++ Objective::isSetType方法的具体用法?C++ Objective::isSetType怎么用?C++ Objective::isSetType使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Objective
的用法示例。
在下文中一共展示了Objective::isSetType方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: checkFbc
void checkFbc(FbcModelPlugin* fbcmodplug, set<string>& components, set<string>& tests, const map<string, vector<double> >& results)
{
if (fbcmodplug->isSetStrict() && fbcmodplug->getStrict() == false) {
tests.insert("fbc:NonStrict");
}
List* allElements = fbcmodplug->getAllElements();
for (unsigned int e=0; e<allElements->getSize(); e++) {
SBase* element = static_cast<SBase*>(allElements->get(e));
FluxBound* fluxBound;
Objective* objective;
switch(element->getTypeCode()) {
case SBML_FBC_FLUXBOUND:
components.insert("fbc:FluxBound");
fluxBound = static_cast<FluxBound*>(element);
if (fluxBound->isSetOperation()) {
if (fluxBound->getOperation() == "lessEqual") {
tests.insert("fbc:BoundLessEqual");
}
else if (fluxBound->getOperation() == "greaterEqual") {
tests.insert("fbc:BoundGreaterEqual");
}
else if (fluxBound->getOperation() == "equal") {
tests.insert("fbc:BoundEqual");
}
}
break;
case SBML_FBC_OBJECTIVE:
components.insert("fbc:Objective");
objective = static_cast<Objective*>(element);
if (objective->isSetType()) {
if (objective->getType() == "maximize") {
tests.insert("fbc:MaximizeObjective");
}
else {
tests.insert("fbc:MinimizeObjective");
}
}
break;
case SBML_FBC_FLUXOBJECTIVE:
components.insert("fbc:FluxObjective");
break;
default:
break;
}
}
}