use of org.sbolstandard.core.datatree.NamedProperty in project libSBOLj by SynBioDex.
the class SBOLWriter method formatModuleDefinitions.
private static void formatModuleDefinitions(Set<ModuleDefinition> module, List<TopLevelDocument<QName>> topLevelDoc) {
for (ModuleDefinition m : module) {
List<NamedProperty<QName>> list = new ArrayList<>();
formatCommonTopLevelData(list, m);
for (URI role : m.getRoles()) {
list.add(NamedProperty(Sbol2Terms.ModuleDefinition.roles, role));
}
formatFunctionalComponents(m.getFunctionalComponents(), list);
formatInteractions(m.getInteractions(), list);
formatModelProperties(m.getModelURIs(), list);
formatModule(m.getModules(), list);
topLevelDoc.add(TopLevelDocument(Sbol2Terms.ModuleDefinition.ModuleDefinition, m.getIdentity(), NamedProperties(list)));
}
}
use of org.sbolstandard.core.datatree.NamedProperty in project libSBOLj by SynBioDex.
the class SBOLWriter method formatAssociations.
private static void formatAssociations(Set<Association> associations, List<NamedProperty<QName>> properties) {
for (Association association : associations) {
List<NamedProperty<QName>> list = new ArrayList<>();
formatCommonIdentifiedData(list, association);
for (URI role : association.getRoles()) {
list.add(NamedProperty(Sbol2Terms.Association.role, role));
}
list.add(NamedProperty(Sbol2Terms.Association.agent, association.getAgentURI()));
if (association.isSetPlan()) {
list.add(NamedProperty(Sbol2Terms.Association.plan, association.getPlanURI()));
}
properties.add(NamedProperty(Sbol2Terms.Activity.qualifiedAssociation, NestedDocument(Sbol2Terms.Association.Association, association.getIdentity(), NamedProperties(list))));
}
}
Aggregations