|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectfern.network.fernml.FernMLAnnotationManager
public class FernMLAnnotationManager
AnnotationManager
for FernMLNetwork
s. The data is not copied but maintained within the tree (which should not be an efficiency
issue except you want to use the annotations to store user data of reactions / species and
do this very excessive - so don't do that). This avoids problems when saving the
FernMLNetwork
again.
Constructor Summary | |
---|---|
FernMLAnnotationManager(org.jdom.Element rootElement)
Create the AnnotationManager from the root element of the jdom tree. |
Method Summary | |
---|---|
boolean |
containsNetworkAnnotation(String typ)
Returns true iff the network contains an annotation of the specified type. |
boolean |
containsReactionAnnotation(int reaction,
String typ)
Returns true iff the reaction contains an annotation of the specified type. |
boolean |
containsSpeciesAnnotation(int species,
String typ)
Returns true iff the species contains an annotation of the specified type. |
String |
getNetworkAnnotation(String typ)
Gets the network annotation of the specified field. |
Collection<String> |
getNetworkAnnotationTypes()
Gets the names of the network reaction. |
String |
getReactionAnnotation(int reaction,
String typ)
Gets the reaction annotation of the specified field. |
Collection<String> |
getReactionAnnotationTypes(int reaction)
Gets the names of the species reaction. |
String |
getSpeciesAnnotation(int species,
String typ)
Gets the species annotation of the specified field. |
Collection<String> |
getSpeciesAnnotationTypes(int species)
Gets the names of the species annotations. |
void |
setNetworkAnnotation(String typ,
String annotation)
Sets the network annotation of the specified field. |
void |
setReactionAnnotation(int reaction,
String typ,
String annotation)
Sets the reaction annotation of the specified field. |
void |
setSpeciesAnnotation(int species,
String typ,
String annotation)
Sets the species annotation of the specified field. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FernMLAnnotationManager(org.jdom.Element rootElement)
AnnotationManager
from the root element of the jdom tree.
rootElement
- the root element of the jdom treeMethod Detail |
---|
public boolean containsNetworkAnnotation(String typ)
AnnotationManager
containsNetworkAnnotation
in interface AnnotationManager
typ
- field name of the annotation
public String getNetworkAnnotation(String typ)
AnnotationManager
getNetworkAnnotation
in interface AnnotationManager
typ
- name of the field
public Collection<String> getNetworkAnnotationTypes()
AnnotationManager
getNetworkAnnotationTypes
in interface AnnotationManager
public void setNetworkAnnotation(String typ, String annotation)
AnnotationManager
setNetworkAnnotation
in interface AnnotationManager
typ
- name of the fieldannotation
- network annotationpublic boolean containsReactionAnnotation(int reaction, String typ)
AnnotationManager
containsReactionAnnotation
in interface AnnotationManager
reaction
- index of the reactiontyp
- field name of the annotation
public String getReactionAnnotation(int reaction, String typ)
AnnotationManager
getReactionAnnotation
in interface AnnotationManager
reaction
- index of the reactiontyp
- name of the field
public Collection<String> getReactionAnnotationTypes(int reaction)
AnnotationManager
getReactionAnnotationTypes
in interface AnnotationManager
reaction
- index of the reaction
public void setReactionAnnotation(int reaction, String typ, String annotation)
AnnotationManager
setReactionAnnotation
in interface AnnotationManager
reaction
- index of the reactiontyp
- name of the fieldannotation
- reaction annotationpublic boolean containsSpeciesAnnotation(int species, String typ)
AnnotationManager
containsSpeciesAnnotation
in interface AnnotationManager
species
- index of the speciestyp
- field name of the annotation
public String getSpeciesAnnotation(int species, String typ)
AnnotationManager
getSpeciesAnnotation
in interface AnnotationManager
species
- index of the speciestyp
- name of the field
public Collection<String> getSpeciesAnnotationTypes(int species)
AnnotationManager
getSpeciesAnnotationTypes
in interface AnnotationManager
species
- index of the species
public void setSpeciesAnnotation(int species, String typ, String annotation)
AnnotationManager
setSpeciesAnnotation
in interface AnnotationManager
species
- index of the speciestyp
- name of the fieldannotation
- species annotation
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |