org.sbml.jsbml
public class Reaction extends AbstractNamedSBase implements CallableSBase, UniqueNamedSBase
| Modifier and Type | Field and Description |
|---|---|
private java.lang.String |
compartmentID
Represents the 'compartment' XML attribute of a reaction element.
|
private java.lang.Boolean |
fast
Represents the 'fast' XML attribute of a reaction element.
|
private boolean |
isSetFast
Checks whether the
fast attribute has been set by using a default or
by changing its value. |
private boolean |
isSetReversible
Checks whether the
reversible attribute has been set by using a default or
by changing its value. |
private KineticLaw |
kineticLaw
Represents the 'kineticLaw' XML subNode of a reaction element.
|
private ListOf<ModifierSpeciesReference> |
listOfModifiers
Represents the 'listOfModifiers' XML subNode of a reaction element.
|
private ListOf<SpeciesReference> |
listOfProducts
Represents the 'listOfProducts' XML subNode of a reaction element.
|
private ListOf<SpeciesReference> |
listOfReactants
Represents the 'listOfReactants' XML subNode of a reaction element.
|
private java.lang.Boolean |
reversible
Represents the 'reversible' XML attribute of a reaction element.
|
private static long |
serialVersionUID
Generated serial version identifier.
|
ignoredExtensions, ignoredXMLElements, lvlistOfListeners, parent, UNKNOWN_ATTRIBUTES, UNKNOWN_ELEMENTS| Constructor and Description |
|---|
Reaction()
Creates a Reaction instance.
|
Reaction(int level,
int version) |
Reaction(Reaction reaction)
Creates a Reaction instance from a given reaction.
|
Reaction(java.lang.String id) |
Reaction(java.lang.String id,
int level,
int version)
Creates a
Reaction instance from an id, level and version. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
addModifier(ModifierSpeciesReference modspecref)
Adds a
ModifierSpeciesReference instance to this Reaction. |
boolean |
addProduct(SpeciesReference specref)
Adds a
SpeciesReference instance to the listOfProducts of this Reaction. |
boolean |
addReactant(SpeciesReference specref)
Adds a
SpeciesReference instance to the listOfReactants of this Reaction. |
Reaction |
clone()
Creates a deep copy of this object, i.e., a new
SBase with the same properties
like this one. |
boolean |
containsUndeclaredUnits()
Returns
true or false depending on whether this
SBaseWithDerivedUnit refers to elements such as parameters or
numbers with undeclared units. |
KineticLaw |
createKineticLaw()
Creates a new
KineticLaw object, installs it as this
Reaction's 'kineticLaw' sub-element, and returns it. |
ModifierSpeciesReference |
createModifier()
Creates a new
ModifierSpeciesReference, adds it to this
Reaction's list of modifiers and returns it. |
ModifierSpeciesReference |
createModifier(Species species)
Creates a new
ModifierSpeciesReference, which points to the given
Species, adds it to this Reaction's
listOfModifiers, and returns a pointer to it. |
ModifierSpeciesReference |
createModifier(java.lang.String id) |
ModifierSpeciesReference |
createModifier(java.lang.String id,
Species species)
Creates a new
ModifierSpeciesReference with the given
id as its identifier, which points to the given
Species, adds it to this Reaction's
listOfModifiers, and returns a pointer to it. |
ModifierSpeciesReference |
createModifier(java.lang.String id,
java.lang.String species)
Creates a new
ModifierSpeciesReference with the given
id as its identifier, which points to the Species
with the given id, adds it to this Reaction's
listOfModifiers, and returns a pointer to it. |
SpeciesReference |
createProduct()
|
SpeciesReference |
createProduct(Species species)
Creates a new
SpeciesReference, which points to the given
Species, adds it to this Reaction's
listOfProducts and returns a pointer to it. |
SpeciesReference |
createProduct(java.lang.String id) |
SpeciesReference |
createProduct(java.lang.String id,
Species species)
Creates a new
SpeciesReference with the given id as
its identifier, which points to the given Species, adds it to
this Reaction's listOfProducts and returns a pointer to
it. |
SpeciesReference |
createProduct(java.lang.String id,
java.lang.String species) |
SpeciesReference |
createReactant()
|
SpeciesReference |
createReactant(Species species)
|
SpeciesReference |
createReactant(java.lang.String id) |
SpeciesReference |
createReactant(java.lang.String id,
Species species)
Creates a new
SpeciesReference with the given id as
identifier, which points to the given Species and adds it to the
listOfReactants. |
SpeciesReference |
createReactant(java.lang.String id,
java.lang.String species) |
boolean |
equals(java.lang.Object object)
|
boolean |
getAllowsChildren() |
javax.swing.tree.TreeNode |
getChildAt(int index) |
int |
getChildCount() |
java.lang.String |
getCompartment()
Only available if Level >= 3.
|
Compartment |
getCompartmentInstance() |
UnitDefinition |
getDerivedUnitDefinition()
This method derives the unit of this quantity and tries to identify an
equivalent
UnitDefinition within the corresponding Model. |
java.lang.String |
getDerivedUnits()
This method derives the unit of this quantity.
|
boolean |
getFast() |
KineticLaw |
getKineticLaw() |
ListOf<ModifierSpeciesReference> |
getListOfModifiers() |
ListOf<SpeciesReference> |
getListOfProducts() |
ListOf<SpeciesReference> |
getListOfReactants() |
ModifierSpeciesReference |
getModifier(int i) |
ModifierSpeciesReference |
getModifier(java.lang.String id)
Searches the first
ModifierSpeciesReference in the
listOfModifiers of this Reaction with the given
identifier. |
int |
getModifierCount() |
ModifierSpeciesReference |
getModifierForSpecies(java.lang.String id)
Returns the first
ModifierSpeciesReference in the
listOfModifiers of this Reaction whose 'species'
attribute points to a Species with the given identifier. |
int |
getNumModifiers() |
int |
getNumProducts() |
int |
getNumReactants() |
ListOf<Reaction> |
getParent()
This is equivalent to calling
AbstractSBase.getParentSBMLObject(), but this
method is needed for TreeNode. |
SpeciesReference |
getProduct(int i) |
SpeciesReference |
getProduct(java.lang.String id)
Searches the first
SpeciesReference in the listOfProducts of this
Reaction with the given identifier. |
int |
getProductCount() |
SpeciesReference |
getProductForSpecies(java.lang.String id)
Returns the first
SpeciesReference in the listOfProducts
of this Reaction whose 'species' attribute points to a
Species with the given identifier. |
SpeciesReference |
getReactant(int i) |
SpeciesReference |
getReactant(java.lang.String id)
Searches the first
SpeciesReference in the listOfReactants of
this Reaction with the given identifier. |
int |
getReactantCount() |
SpeciesReference |
getReactantForSpecies(java.lang.String id)
Returns the first
SpeciesReference in the
listOfReactants of this Reaction whose 'species'
attribute points to a Species with the given identifier. |
boolean |
getReversible() |
int |
hashCode() |
boolean |
hasModifier(Species s) |
boolean |
hasProduct(Species s) |
boolean |
hasReactant(Species s) |
void |
initDefaults()
Initializes the default values using the current Level/Version configuration.
|
void |
initDefaults(int level,
int version)
Initializes the default variables of this Reaction.
|
boolean |
involves(Species s)
Convenient test if the given species takes part in this reaction as a
reactant, product, or modifier.
|
boolean |
isFast() |
boolean |
isIdMandatory()
This method can be used to query if the identifier of this
NamedSBase is required to be defined (i.e., not null)
in the definition of SBML. |
boolean |
isReversible() |
boolean |
isSetCompartment() |
boolean |
isSetCompartmentInstance() |
boolean |
isSetFast() |
boolean |
isSetKineticLaw() |
boolean |
isSetListOfModifiers() |
boolean |
isSetListOfProducts() |
boolean |
isSetListOfReactants() |
boolean |
isSetReversible() |
boolean |
readAttribute(java.lang.String attributeName,
java.lang.String prefix,
java.lang.String value)
If the attribute is an id or name attribute, it will set the id or name
of this object with the value of the XML attribute ('value').
|
private boolean |
references(ListOf<? extends SimpleSpeciesReference> list,
Species s)
Checks whether the given list references the given species.
|
private <T extends SimpleSpeciesReference> |
remove(ListOf<T> list,
java.lang.String id) |
ModifierSpeciesReference |
removeModifier(int i)
Removes the nth modifier species (ModifierSpeciesReference object) in the
list of modifiers in this Reaction and returns it.
|
boolean |
removeModifier(ModifierSpeciesReference modspecref)
Removes the ModifierSpeciesReference 'modspecref' from this Reaction.
|
ModifierSpeciesReference |
removeModifier(java.lang.String id)
Removes the modifier species (ModifierSpeciesReference object) having the
given 'species' attribute in the list of modifiers in this Reaction and
returns it.
|
SpeciesReference |
removeProduct(int i)
Removes the nth product species (SpeciesReference object) in the list of
products in this Reaction and returns it.
|
void |
removeProduct(SpeciesReference specref)
Removes the SpeciesReference 'modspecref' from the listOfProducts of this
Reaction.
|
SpeciesReference |
removeProduct(java.lang.String id)
Removes the product species (SpeciesReference object) having the given
'species' attribute in the list of products in this Reaction and returns
it.
|
SpeciesReference |
removeReactant(int i)
Removes the nth reactant species (SpeciesReference object) in the list of
reactants in this Reaction and returns it.
|
boolean |
removeReactant(SpeciesReference specref)
Removes the SpeciesReference 'modspecref' from the listOfReactants of
this Reaction.
|
SpeciesReference |
removeReactant(java.lang.String id)
Removes the reactant species (SpeciesReference object) having the given
'species' attribute in the list of reactants in this Reaction and returns
it.
|
void |
setCompartment(Compartment compartment)
Sets the compartmentID of this
Reaction to the id of the Compartment
'compartment'. |
void |
setCompartment(java.lang.String compartmentID)
Sets the compartmentID of this Reaction to 'compartmentID'.
|
void |
setFast(boolean fast)
Sets the fast Boolean of this
Reaction. |
void |
setKineticLaw(KineticLaw kineticLaw)
Sets the kineticLaw of this
Reaction. |
void |
setListOfModifiers(ListOf<ModifierSpeciesReference> listOfModifiers)
Sets the listOfModifiers of this
Reaction. |
void |
setListOfProducts(ListOf<SpeciesReference> listOfProducts)
Sets the
listOfProducts of this Reaction. |
void |
setListOfReactants(ListOf<SpeciesReference> listOfReactants)
Sets the listOfReactants of this
Reaction. |
void |
setReversible(boolean reversible)
Sets the reversible Boolean of this
Reaction. |
void |
unsetFast()
Sets the fast Boolean of this Reaction to
null. |
boolean |
unsetKineticLaw()
|
boolean |
unsetListOfModifiers()
Removes the
listOfModifiers from this Reaction and notifies
all registered instances of TreeNodeChangeListener. |
boolean |
unsetListOfProducts()
Removes the
listOfProducts from this Reaction and notifies
all registered instances of TreeNodeChangeListener. |
boolean |
unsetListOfReactants()
Removes the
listOfReactants from this Reaction and notifies
all registered instances of TreeNodeChangeListener. |
void |
unsetReversible()
Sets the reversible Boolean of this
Reaction to null. |
java.util.Map<java.lang.String,java.lang.String> |
writeXMLAttributes() |
checkIdentifier, getId, getName, isSetId, isSetName, isValidId, setId, setName, toString, unsetId, unsetNameaddCVTerm, addDeclaredNamespace, addExtension, appendNotes, appendNotes, checkLevelAndVersionCompatibility, createHistory, createPlugin, disablePackage, enablePackage, enablePackage, filterCVTerms, filterCVTerms, filterCVTerms, fireNodeRemovedEvent, getAnnotation, getAnnotationString, getCVTerm, getCVTermCount, getCVTerms, getDeclaredNamespaces, getElementName, getExtension, getExtensionPackages, getHistory, getLevel, getLevelAndVersion, getMetaId, getModel, getNamespace, getNotes, getNotesString, getNumCVTerms, getNumPlugins, getParentSBMLObject, getPlugin, getSBMLDocument, getSBOTerm, getSBOTermID, getVersion, hasValidAnnotation, hasValidLevelVersionNamespaceCombination, isExtendedByOtherPackages, isPackageEnabled, isPackageURIEnabled, isPkgEnabled, isPkgURIEnabled, isSetAnnotation, isSetHistory, isSetLevel, isSetLevelAndVersion, isSetMetaId, isSetNotes, isSetParentSBMLObject, isSetPlugin, isSetSBOTerm, isSetVersion, isValidLevelAndVersionCombination, isValidMetaId, notifyChildChange, registerChild, setAnnotation, setHistory, setLevel, setLevelAndVersion, setMetaId, setNamespace, setNotes, setNotes, setParentSBML, setParentSBMLObject, setSBOTerm, setSBOTerm, setThisAsParentSBMLObject, setVersion, unregister, unsetAnnotation, unsetCVTerms, unsetExtension, unsetHistory, unsetMetaId, unsetNamespace, unsetNotes, unsetPlugin, unsetSBOTermaddAllChangeListeners, addTreeNodeChangeListener, addTreeNodeChangeListener, children, clearUserObjects, containsUserObjectKey, filter, filter, filter, fireNodeAddedEvent, firePropertyChange, getIndex, getListOfTreeNodeChangeListeners, getNumChildren, getRoot, getTreeNodeChangeListenerCount, getUserObject, indexOf, isLeaf, isRoot, isSetParent, isSetUserObjects, putUserObject, removeAllTreeNodeChangeListeners, removeFromParent, removeTreeNodeChangeListener, removeTreeNodeChangeListener, removeUserObject, setParent, userObjectKeySetfinalize, getClass, notify, notifyAll, wait, wait, waitgetId, getName, isSetId, isSetName, setId, setName, unsetId, unsetNameaddCVTerm, addDeclaredNamespace, addExtension, appendNotes, appendNotes, createPlugin, disablePackage, enablePackage, enablePackage, filterCVTerms, filterCVTerms, filterCVTerms, getAnnotation, getAnnotationString, getCVTerm, getCVTermCount, getCVTerms, getDeclaredNamespaces, getElementName, getExtension, getExtensionPackages, getHistory, getLevel, getLevelAndVersion, getMetaId, getModel, getNamespace, getNotes, getNotesString, getNumCVTerms, getNumPlugins, getParentSBMLObject, getPlugin, getSBMLDocument, getSBOTerm, getSBOTermID, getVersion, hasValidAnnotation, hasValidLevelVersionNamespaceCombination, isExtendedByOtherPackages, isPackageEnabled, isPackageURIEnabled, isPkgEnabled, isPkgURIEnabled, isSetAnnotation, isSetHistory, isSetLevel, isSetLevelAndVersion, isSetMetaId, isSetNotes, isSetParentSBMLObject, isSetPlugin, isSetSBOTerm, isSetVersion, registerChild, removeTreeNodeChangeListener, setAnnotation, setHistory, setLevel, setMetaId, setNotes, setNotes, setSBOTerm, setSBOTerm, setThisAsParentSBMLObject, setVersion, unregister, unsetAnnotation, unsetCVTerms, unsetExtension, unsetHistory, unsetMetaId, unsetNotes, unsetPlugin, unsetSBOTermaddAllChangeListeners, addTreeNodeChangeListener, addTreeNodeChangeListener, clearUserObjects, containsUserObjectKey, filter, filter, filter, fireNodeAddedEvent, fireNodeRemovedEvent, firePropertyChange, getListOfTreeNodeChangeListeners, getRoot, getTreeNodeChangeListenerCount, getUserObject, isRoot, isSetParent, isSetUserObjects, putUserObject, removeAllTreeNodeChangeListeners, removeFromParent, removeTreeNodeChangeListener, removeUserObject, userObjectKeySetprivate static final long serialVersionUID
private java.lang.String compartmentID
private java.lang.Boolean fast
private boolean isSetFast
fast attribute has been set by using a default or
by changing its value.private boolean isSetReversible
reversible attribute has been set by using a default or
by changing its value.private KineticLaw kineticLaw
private ListOf<ModifierSpeciesReference> listOfModifiers
private ListOf<SpeciesReference> listOfProducts
private ListOf<SpeciesReference> listOfReactants
private java.lang.Boolean reversible
public Reaction()
listOfReactants, listOfProducts and
listOfModifiers are empty.public Reaction(int level,
int version)
id - public Reaction(Reaction reaction)
reaction - public Reaction(java.lang.String id)
id - public Reaction(java.lang.String id,
int level,
int version)
Reaction instance from an id, level and version. By default,
the compartmentID, kineticLaw, listOfReactants, listOfProducts and
listOfModifiers are empty.id - level - version - public boolean addModifier(ModifierSpeciesReference modspecref)
ModifierSpeciesReference instance to this Reaction.modspecref - true if the listOfModifiers was
changed as a result of this call.public boolean addProduct(SpeciesReference specref)
SpeciesReference instance to the listOfProducts of this Reaction.specref - true if the listOfProducts was
changed as a result of this call.public boolean addReactant(SpeciesReference specref)
SpeciesReference instance to the listOfReactants of this Reaction.specref - true if the listOfReactants was
changed as a result of this call.public Reaction clone()
SBaseSBase with the same properties
like this one.clone in interface SBaseclone in class AbstractSBasepublic boolean containsUndeclaredUnits()
SBaseWithDerivedUnittrue or false depending on whether this
SBaseWithDerivedUnit refers to elements such as parameters or
numbers with undeclared units.
A return value of true indicates that the UnitDefinition
returned by SBaseWithDerivedUnit.getDerivedUnitDefinition() may not accurately
represent the units of the expression.containsUndeclaredUnits in interface SBaseWithDerivedUnittrue if the math expression of this SBaseWithDerivedUnit
includes parameters/numbers with undeclared units,
false otherwise.public KineticLaw createKineticLaw()
KineticLaw object, installs it as this
Reaction's 'kineticLaw' sub-element, and returns it.
If this Reaction had a previous KineticLaw, it will be destroyed.KineticLaw objectpublic ModifierSpeciesReference createModifier()
ModifierSpeciesReference, adds it to this
Reaction's list of modifiers and returns it.ModifierSpeciesReference object.public ModifierSpeciesReference createModifier(Species species)
ModifierSpeciesReference, which points to the given
Species, adds it to this Reaction's
listOfModifiers, and returns a pointer to it.species - the Species to which this modifier should point.createModifier(String, Species)public ModifierSpeciesReference createModifier(java.lang.String id)
id - public ModifierSpeciesReference createModifier(java.lang.String id, Species species)
ModifierSpeciesReference with the given
id as its identifier, which points to the given
Species, adds it to this Reaction's
listOfModifiers, and returns a pointer to it.id - the identifier of the ModifierSpeciesReference to be
created.species - the Species to which this modifier should point.ModifierSpeciesReference.public ModifierSpeciesReference createModifier(java.lang.String id, java.lang.String species)
ModifierSpeciesReference with the given
id as its identifier, which points to the Species
with the given id, adds it to this Reaction's
listOfModifiers, and returns a pointer to it.id - the identifier of the ModifierSpeciesReference to be
created.species - the identifier of the Species to be referenced.ModifierSpeciesReference.public SpeciesReference createProduct()
SpeciesReference object.public SpeciesReference createProduct(Species species)
SpeciesReference, which points to the given
Species, adds it to this Reaction's
listOfProducts and returns a pointer to it.species - the Species to which the SpeciesReference
should point.SpeciesReference that has
been added to this Reaction's listOfProducts.createProduct(String, Species)public SpeciesReference createProduct(java.lang.String id)
id - public SpeciesReference createProduct(java.lang.String id, Species species)
SpeciesReference with the given id as
its identifier, which points to the given Species, adds it to
this Reaction's listOfProducts and returns a pointer to
it.id - the identifier of the SpeciesReference to be created.species - the Species to which the SpeciesReference
should point.SpeciesReference that has
been added to this Reaction's listOfProducts.public SpeciesReference createProduct(java.lang.String id, java.lang.String species)
id - species - public SpeciesReference createReactant()
public SpeciesReference createReactant(Species species)
species - SpeciesReference that
points to the given Species.createReactant(String, Species)public SpeciesReference createReactant(java.lang.String id)
id - public SpeciesReference createReactant(java.lang.String id, Species species)
SpeciesReference with the given id as
identifier, which points to the given Species and adds it to the
listOfReactants.id - the identifier of the SpeciesReference to be created.species - the Species to which this reactant should point.SpeciesReference.public SpeciesReference createReactant(java.lang.String id, java.lang.String species)
id - species - public boolean equals(java.lang.Object object)
SBasetrue if and only if the given SBase has exactly the same
properties like this SBase instance.equals in interface SBaseequals in class AbstractNamedSBasetrue if and only if the given Object is an instance of
SBase that has exactly the same properties like this
SBase instance.public boolean getAllowsChildren()
getAllowsChildren in interface javax.swing.tree.TreeNodegetAllowsChildren in class AbstractSBasepublic javax.swing.tree.TreeNode getChildAt(int index)
getChildAt in interface javax.swing.tree.TreeNodegetChildAt in class AbstractSBasepublic int getChildCount()
getChildCount in interface javax.swing.tree.TreeNodegetChildCount in class AbstractSBasepublic java.lang.String getCompartment()
Reaction. The empty
String if it is not set.public Compartment getCompartmentInstance()
public UnitDefinition getDerivedUnitDefinition()
SBaseWithDerivedUnitUnitDefinition within the corresponding Model.
If no equivalent unit definition can be found, a new unit definition will
be created that is not part of the model but represents the unit of this
quantity. If it is not possible to derive a unit for this quantity, null
will be returned.getDerivedUnitDefinition in interface SBaseWithDerivedUnitpublic java.lang.String getDerivedUnits()
SBaseWithDerivedUnitUnit.Kind this
method will return the String representation of this
Unit.Kind.getDerivedUnits in interface SBaseWithDerivedUnitpublic boolean getFast()
public KineticLaw getKineticLaw()
public ListOf<ModifierSpeciesReference> getListOfModifiers()
public ListOf<SpeciesReference> getListOfProducts()
public ListOf<SpeciesReference> getListOfReactants()
public ModifierSpeciesReference getModifier(int i)
i - public ModifierSpeciesReference getModifier(java.lang.String id)
ModifierSpeciesReference in the
listOfModifiers of this Reaction with the given
identifier.id - identifier of the desired ModifierSpeciesReference.
Note that this is not the identifier of the Species.ModifierSpeciesReference of the
listOfModifiers which has 'id' as id (or name depending
on the level and version). Can be null if it doesn't exist.public int getModifierCount()
ModifierSpeciesReferences of this
Reaction.public ModifierSpeciesReference getModifierForSpecies(java.lang.String id)
ModifierSpeciesReference in the
listOfModifiers of this Reaction whose 'species'
attribute points to a Species with the given identifier.id - The identifier of a referenced SpeciesModifierSpeciesReference of the
listOfModifiers which has 'id' as species attribute (or
name depending on the level and version). Can be null if it
doesn't exist.public int getNumModifiers()
ModifierSpeciesReferences of this
Reaction.public int getNumProducts()
SpeciesReference.public int getNumReactants()
SpeciesReference.public ListOf<Reaction> getParent()
AbstractSBaseAbstractSBase.getParentSBMLObject(), but this
method is needed for TreeNode.getParent in interface javax.swing.tree.TreeNodegetParent in class AbstractSBaseAbstractSBase.getParentSBMLObject()public SpeciesReference getProduct(int i)
i - public SpeciesReference getProduct(java.lang.String id)
SpeciesReference in the listOfProducts of this
Reaction with the given identifier.id - identifier of the desired SpeciesReference. Note that
this is not the identifier of the Species.SpeciesReference of the listOfProducts which has 'id' as id
(or name depending on the level and version). Can be null if it
doesn't exist.public int getProductCount()
SpeciesReference.public SpeciesReference getProductForSpecies(java.lang.String id)
SpeciesReference in the listOfProducts
of this Reaction whose 'species' attribute points to a
Species with the given identifier.id - The identifier of a referenced SpeciesSpeciesReference of the listOfProducts which
has 'id' as species attribute (or name depending on the level and
version). Can be null if it doesn't exist.public SpeciesReference getReactant(int i)
i - SpeciesReference of the listOfReactants.
Can be null if it doesn't exist.public SpeciesReference getReactant(java.lang.String id)
SpeciesReference in the listOfReactants of
this Reaction with the given identifier.id - identifier of the desired SpeciesReference. Note that
this is not the identifier of the Species.SpeciesReference of the listOfReactants which has
'id' as id (or name depending on the level and version). Can be
null if it doesn't exist.public int getReactantCount()
SpeciesReference.public SpeciesReference getReactantForSpecies(java.lang.String id)
SpeciesReference in the
listOfReactants of this Reaction whose 'species'
attribute points to a Species with the given identifier.id - The identifier of a referenced SpeciesSpeciesReference of the listOfReactants
which has 'id' as species attribute (or name depending on the
level and version). Can be null if it doesn't exist.public boolean getReversible()
public int hashCode()
hashCode in interface SBasehashCode in class AbstractNamedSBaseObject.hashCode()public boolean hasModifier(Species s)
s - public boolean hasProduct(Species s)
s - public boolean hasReactant(Species s)
s - public void initDefaults()
public void initDefaults(int level,
int version)
public boolean involves(Species s)
s - public boolean isFast()
false otherwise.public boolean isIdMandatory()
NamedSBaseNamedSBase is required to be defined (i.e., not null)
in the definition of SBML.isIdMandatory in interface NamedSBasetrue if the identifier of this element must be set in
order to create a valid SBML representation. false
otherwise, i.e., if the identifier can be understood as an optional
attribute.public boolean isReversible()
false otherwise.public boolean isSetCompartment()
true if the compartmentID of this Reaction is not null.public boolean isSetCompartmentInstance()
true if the Compartment which has the compartmentID of this
Reaction as id is not null;public boolean isSetFast()
true if fast is not null.public boolean isSetKineticLaw()
true if the kineticLaw of this Reaction is not null.public boolean isSetListOfModifiers()
true if the listOfModifiers of this Reaction is not true and not
empty.public boolean isSetListOfProducts()
true if the listOfProducts of this reaction is not true and not
empty.public boolean isSetListOfReactants()
true if the listOfReactants of this Reaction is not true and not
empty.public boolean isSetReversible()
true if reversible is not null.public boolean readAttribute(java.lang.String attributeName,
java.lang.String prefix,
java.lang.String value)
SBasereadAttribute in interface SBasereadAttribute in class AbstractNamedSBaseattributeName - localName of the XML attributeprefix - prefix of the XML attributevalue - value of the XML attributetrue if the attribute has been successfully read.private boolean references(ListOf<? extends SimpleSpeciesReference> list, Species s)
list - s - private <T extends SimpleSpeciesReference> T remove(ListOf<T> list, java.lang.String id)
list - id - public ModifierSpeciesReference removeModifier(int i)
i - the index of the ModifierSpeciesReference object to remove.public boolean removeModifier(ModifierSpeciesReference modspecref)
modspecref - public ModifierSpeciesReference removeModifier(java.lang.String id)
id - the 'species' attribute of the ModifierSpeciesReference object
(which correspond to a species id).public SpeciesReference removeProduct(int i)
i - the index of the SpeciesReference object to remove.public void removeProduct(SpeciesReference specref)
specref - public SpeciesReference removeProduct(java.lang.String id)
id - the 'species' attribute of the SpeciesReference object (which
correspond to a species id).public SpeciesReference removeReactant(int i)
i - the index of the SpeciesReference object to remove.public boolean removeReactant(SpeciesReference specref)
specref - public SpeciesReference removeReactant(java.lang.String id)
id - the 'species' attribute of the SpeciesReference object (which
correspond to a species id).public void setCompartment(Compartment compartment)
Reaction to the id of the Compartment
'compartment'.compartment - public void setCompartment(java.lang.String compartmentID)
compartmentID - PropertyNotAvailableException - if Level < 3.public void setFast(boolean fast)
Reaction.fast - public void setKineticLaw(KineticLaw kineticLaw)
Reaction.kineticLaw - public void setListOfModifiers(ListOf<ModifierSpeciesReference> listOfModifiers)
Reaction. Automatically sets the
parentSBML object of the list to this Reaction instance.listOfModifiers - public void setListOfProducts(ListOf<SpeciesReference> listOfProducts)
listOfProducts of this Reaction. Automatically sets the
parentSBML object of the list to this Reaction instance.listOfProducts - public void setListOfReactants(ListOf<SpeciesReference> listOfReactants)
Reaction. Automatically sets the
parentSBML object of the list to this Reaction instance.listOfReactants - public void setReversible(boolean reversible)
Reaction.reversible - public void unsetFast()
null.public boolean unsetKineticLaw()
true if calling this method changed the properties
of this element.public boolean unsetListOfModifiers()
listOfModifiers from this Reaction and notifies
all registered instances of TreeNodeChangeListener.true if calling this method lead to a change in this
data structure.public boolean unsetListOfProducts()
listOfProducts from this Reaction and notifies
all registered instances of TreeNodeChangeListener.true if calling this method lead to a change in this
data structure.public boolean unsetListOfReactants()
listOfReactants from this Reaction and notifies
all registered instances of TreeNodeChangeListener.true if calling this method lead to a change in this
data structure.public void unsetReversible()
Reaction to null.public java.util.Map<java.lang.String,java.lang.String> writeXMLAttributes()
writeXMLAttributes in interface SBasewriteXMLAttributes in class AbstractNamedSBaseMap containing the XML attributes of this object.