use of cbit.vcell.model.ModelRuleFactory in project vcell by virtualcell.
the class ParticipantSignatureShapePanel method refreshRuleAnalysis.
private void refreshRuleAnalysis() {
reportMap.clear();
modelRuleEntryMap.clear();
bRuleAnalysisFailedMap.clear();
if (reactionRuleMap == null || reactionRuleMap.isEmpty()) {
return;
}
for (Map.Entry<String, ReactionRule> entry : reactionRuleMap.entrySet()) {
String key = entry.getKey();
ReactionRule rr = entry.getValue();
ModelRuleFactory factory = new ModelRuleFactory();
ModelRuleEntry modelRuleEntry = factory.createRuleEntry(rr, 0, ReactionRuleDirection.forward);
try {
RuleAnalysisReport report = RuleAnalysis.analyze(modelRuleEntry, false);
reportMap.put(key, report);
modelRuleEntryMap.put(key, modelRuleEntry);
bRuleAnalysisFailedMap.put(key, false);
} catch (Exception e) {
e.printStackTrace();
System.err.println("exception computing RuleAnalysis report for " + key + ": " + e.getMessage());
bRuleAnalysisFailedMap.put(key, true);
bRuleAnalysisFailed = true;
}
}
}
use of cbit.vcell.model.ModelRuleFactory in project vcell by virtualcell.
the class RulesShapePanel method refreshRuleAnalysis.
private void refreshRuleAnalysis() {
if (reactionRule == null) {
bRuleAnalysisFailed = true;
return;
}
ModelRuleFactory factory = new ModelRuleFactory();
this.modelRuleEntry = factory.createRuleEntry(reactionRule, 0, ReactionRuleDirection.forward);
try {
this.report = RuleAnalysis.analyze(modelRuleEntry, false);
this.bRuleAnalysisFailed = false;
} catch (Exception e) {
e.printStackTrace();
System.err.println("exception computing RuleAnalysis report: " + e.getMessage());
bRuleAnalysisFailed = true;
}
}
Aggregations