org.sbml.jsbml
public abstract class QuantityWithUnit extends AbstractNamedSBaseWithUnit implements Quantity
Modifier and Type | Field and Description |
---|---|
private boolean |
isSetValue
a boolean to help knowing is the value as been set by the user or is the
default one.
|
private static long |
serialVersionUID
Generated serial version identifier.
|
protected java.lang.Double |
value
The size, initial amount or concentration, or the actual value of this
variable.
|
unitsID
ignoredExtensions, ignoredXMLElements, lv
listOfListeners, parent, UNKNOWN_ATTRIBUTES, UNKNOWN_ELEMENTS
Constructor and Description |
---|
QuantityWithUnit() |
QuantityWithUnit(int level,
int version) |
QuantityWithUnit(QuantityWithUnit qwdu) |
QuantityWithUnit(java.lang.String id) |
QuantityWithUnit(java.lang.String id,
int level,
int version) |
QuantityWithUnit(java.lang.String id,
java.lang.String name,
int level,
int version) |
Modifier and Type | Method and Description |
---|---|
abstract QuantityWithUnit |
clone()
Creates a deep copy of this object, i.e., a new
SBase with the same properties
like this one. |
boolean |
equals(java.lang.Object object)
|
double |
getValue()
Returns the value of this
Quantity . |
int |
hashCode()
Returns a hash code value for this
SBase instance. |
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 |
isSetValue()
Returns
true if the value of this Quantity is set. |
void |
setValue(double value)
Sets the value of this
Quantity . |
void |
unsetValue()
Unsets the value of this
Quantity . |
containsUndeclaredUnits, getDerivedUnitDefinition, getDerivedUnits, getPredefinedUnitID, getUnits, getUnitsInstance, isPredefinedUnitsID, isSetUnits, isSetUnitsInstance, setUnits, setUnits, setUnits, setUnits, unsetUnits
checkIdentifier, getId, getName, isSetId, isSetName, isValidId, readAttribute, setId, setName, toString, unsetId, unsetName, writeXMLAttributes
addCVTerm, addDeclaredNamespace, addExtension, addPlugin, appendNotes, appendNotes, checkLevelAndVersionCompatibility, createHistory, createPlugin, disablePackage, enablePackage, enablePackage, filterCVTerms, filterCVTerms, filterCVTerms, filterCVTerms, fireNodeRemovedEvent, firePropertyChange, getAllowsChildren, getAnnotation, getAnnotationString, getChildAt, getChildCount, getCVTerm, getCVTermCount, getCVTerms, getDeclaredNamespaces, getElementName, getExtension, getExtensionCount, getExtensionPackages, getHistory, getIdManager, getLevel, getLevelAndVersion, getMetaId, getModel, getNamespace, getNotes, getNotesString, getNumCVTerms, getNumPlugins, getParent, 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, removeCVTerm, removeCVTerm, setAnnotation, setHistory, setLevel, setLevelAndVersion, setMetaId, setNamespace, setNotes, setNotes, setParentSBML, setParentSBMLObject, setSBOTerm, setSBOTerm, setThisAsParentSBMLObject, setVersion, unregisterChild, unsetAnnotation, unsetCVTerms, unsetExtension, unsetHistory, unsetMetaId, unsetNamespace, unsetNotes, unsetPlugin, unsetSBOTerm
addAllChangeListeners, addAllChangeListeners, addTreeNodeChangeListener, addTreeNodeChangeListener, children, clearUserObjects, containsUserObjectKey, filter, filter, filter, fireNodeAddedEvent, getIndex, getListOfTreeNodeChangeListeners, getNumChildren, getRoot, getTreeNodeChangeListenerCount, getUserObject, indexOf, isLeaf, isRoot, isSetParent, isSetUserObjects, putUserObject, removeAllTreeNodeChangeListeners, removeAllTreeNodeChangeListeners, removeFromParent, removeTreeNodeChangeListener, removeTreeNodeChangeListener, removeUserObject, setParent, userObjectKeySet
finalize, getClass, notify, notifyAll, wait, wait, wait
getId, getName, isSetId, isSetName, setId, setName, unsetId, unsetName
containsUndeclaredUnits, getDerivedUnitDefinition, getDerivedUnits
addCVTerm, addDeclaredNamespace, addExtension, addPlugin, appendNotes, appendNotes, createPlugin, disablePackage, enablePackage, enablePackage, filterCVTerms, filterCVTerms, filterCVTerms, filterCVTerms, getAnnotation, getAnnotationString, getCVTerm, getCVTermCount, getCVTerms, getDeclaredNamespaces, getElementName, getExtension, getExtensionCount, 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, readAttribute, registerChild, removeCVTerm, removeCVTerm, removeTreeNodeChangeListener, setAnnotation, setHistory, setLevel, setMetaId, setNotes, setNotes, setSBOTerm, setSBOTerm, setThisAsParentSBMLObject, setVersion, unregisterChild, unsetAnnotation, unsetCVTerms, unsetExtension, unsetHistory, unsetMetaId, unsetNotes, unsetPlugin, unsetSBOTerm, writeXMLAttributes
addAllChangeListeners, addAllChangeListeners, addTreeNodeChangeListener, addTreeNodeChangeListener, clearUserObjects, containsUserObjectKey, filter, filter, filter, fireNodeAddedEvent, fireNodeRemovedEvent, firePropertyChange, getListOfTreeNodeChangeListeners, getRoot, getTreeNodeChangeListenerCount, getUserObject, isRoot, isSetParent, isSetUserObjects, putUserObject, removeAllTreeNodeChangeListeners, removeAllTreeNodeChangeListeners, removeFromParent, removeTreeNodeChangeListener, removeUserObject, userObjectKeySet
private static final long serialVersionUID
private boolean isSetValue
protected java.lang.Double value
public QuantityWithUnit()
public QuantityWithUnit(int level, int version)
level
- version
- public QuantityWithUnit(QuantityWithUnit qwdu)
qwdu
- public QuantityWithUnit(java.lang.String id)
id
- public QuantityWithUnit(java.lang.String id, int level, int version)
id
- level
- version
- public QuantityWithUnit(java.lang.String id, java.lang.String name, int level, int version)
id
- name
- level
- version
- public abstract QuantityWithUnit clone()
SBase
SBase
with the same properties
like this one.clone
in interface SBase
clone
in class AbstractNamedSBaseWithUnit
public boolean equals(java.lang.Object object)
SBase
public double getValue()
Quantity
Quantity
.
In Compartment
s the value is its size, in Species
the
value defines its initial amount or concentration, and in
Parameter
s and LocalParameter
s this returns the value
attribute from SBML.public int hashCode()
SBase
SBase
instance.hashCode
in interface SBase
hashCode
in class AbstractNamedSBaseWithUnit
SBase
instance.Object.hashCode()
public boolean isIdMandatory()
NamedSBase
NamedSBase
is required to be defined (i.e., not null
)
in the definition of SBML.isIdMandatory
in interface NamedSBase
true
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 isSetValue()
Quantity
true
if the value of this Quantity
is set.isSetValue
in interface Quantity
true
if the value of this Quantity
is set.public void setValue(double value)
Quantity
Quantity
.
Note that the meaning of the value can be different in all derived
classes. In Compartment
s the value defines its size. In
Species
the value describes either the initial amount or the
initial concentration. Only the class Parameter
and
LocalParameter
really define a value attribute with this name.public void unsetValue()
Quantity
Quantity
.unsetValue
in interface Quantity