use of org.vcell.pathway.BiochemicalReaction in project vcell by virtualcell.
the class PathwayProducerBiopax3 method addContentBiochemicalReaction.
// deltaG DeltaG multiple
// kEQ KPrime multiple
// eCNumber String multiple
// deltaS Float multiple
// deltaH Float multiple
private Element addContentBiochemicalReaction(BioPaxObject bpObject, Element element) {
element = addContentConversion(bpObject, element);
BiochemicalReaction ob = (BiochemicalReaction) bpObject;
Element tmpElement = null;
if (ob.getDeltaG() != null && ob.getDeltaG().size() > 0) {
List<DeltaG> list = ob.getDeltaG();
for (DeltaG item : list) {
tmpElement = new Element("deltaG", bp);
addIDToProperty(tmpElement, item);
mustPrintObject(item);
element.addContent(tmpElement);
}
}
if (ob.getkEQ() != null && ob.getkEQ().size() > 0) {
List<KPrime> list = ob.getkEQ();
for (KPrime item : list) {
tmpElement = new Element("kEQ", bp);
addIDToProperty(tmpElement, item);
mustPrintObject(item);
element.addContent(tmpElement);
}
}
if (ob.getECNumber() != null && ob.getECNumber().size() > 0) {
List<String> list = ob.getECNumber();
for (String item : list) {
tmpElement = new Element("eCNumber", bp);
tmpElement.setAttribute("datatype", schemaString, rdf);
tmpElement.setText(item);
element.addContent(tmpElement);
}
}
if (ob.getDeltaS() != null && ob.getDeltaS().size() > 0) {
List<Double> list = ob.getDeltaS();
for (Double item : list) {
tmpElement = new Element("deltaS", bp);
tmpElement.setAttribute("datatype", schemaDouble, rdf);
tmpElement.setText(item.toString());
element.addContent(tmpElement);
}
}
if (ob.getDeltaH() != null && ob.getDeltaH().size() > 0) {
List<Double> list = ob.getDeltaH();
for (Double item : list) {
tmpElement = new Element("deltaH", bp);
tmpElement.setAttribute("datatype", schemaDouble, rdf);
tmpElement.setText(item.toString());
element.addContent(tmpElement);
}
}
return element;
}
use of org.vcell.pathway.BiochemicalReaction in project vcell by virtualcell.
the class PathwayReader method addObjectBiochemicalReaction.
private BiochemicalReaction addObjectBiochemicalReaction(Element element) {
BiochemicalReaction biochemicalReaction = new BiochemicalReactionImpl();
addAttributes(biochemicalReaction, element);
for (Object child : element.getChildren()) {
if (child instanceof Element) {
Element childElement = (Element) child;
if (!addContentBiochemicalReaction(biochemicalReaction, element, (Element) child)) {
showUnexpected((Element) child, biochemicalReaction);
}
}
}
pathwayModel.add(biochemicalReaction);
return biochemicalReaction;
}
use of org.vcell.pathway.BiochemicalReaction in project vcell by virtualcell.
the class PathwayReaderBiopax3 method addObjectBiochemicalReaction.
private BiochemicalReaction addObjectBiochemicalReaction(Element element) {
Namespace bp = Namespace.getNamespace("bp", "http://www.biopax.org/release/biopax-level3.owl#");
if (element.getChild("TransportWithBiochemicalReaction", bp) != null) {
return addObjectTransportWithBiochemicalReaction(element.getChild("TransportWithBiochemicalReaction", bp));
}
BiochemicalReaction biochemicalReaction = new BiochemicalReactionImpl();
addAttributes(biochemicalReaction, element);
for (Object child : element.getChildren()) {
if (child instanceof Element) {
Element childElement = (Element) child;
if (!addContentBiochemicalReaction(biochemicalReaction, element, childElement)) {
showUnexpected(childElement);
}
}
}
pathwayModel.add(biochemicalReaction);
return biochemicalReaction;
}
Aggregations