java.io.Serializable
, java.lang.Cloneable
, javax.swing.tree.TreeNode
, SBasePlugin
, TreeNodeWithChangeSupport
public class FBCModelPlugin extends AbstractFBCSBasePlugin
FBCModelPlugin
is the extended Model
class for the FBC package.
It is extended by the addition of two children, list of FluxBound
and list of Objective
Constructor | Description |
---|---|
FBCModelPlugin(FBCModelPlugin fbcPlugin) |
Clone constructor
|
FBCModelPlugin(Model model) |
Creates a new
FBCModelPlugin instance. |
Modifier and Type | Method | Description |
---|---|---|
boolean |
addFluxBound(FluxBound fluxBound) |
Deprecated.
Only defined in FBC version 1.
|
boolean |
addGeneProduct(GeneProduct geneProduct) |
Adds a new
GeneProduct to the listOfGeneProducts . |
boolean |
addObjective(Objective objective) |
Adds a new
Objective to the listOfObjectives. |
FBCModelPlugin |
clone() |
Creates a new instance of
SBasePlugin from this SBasePlugin . |
FluxBound |
createFluxBound() |
Deprecated.
Only defined in FBC version 1.
|
FluxBound |
createFluxBound(java.lang.String id) |
Deprecated.
Only defined in FBC version 1.
|
GeneProduct |
createGeneProduct() |
Creates a new
GeneProduct element and adds it to the ListOfGeneProducts list. |
GeneProduct |
createGeneProduct(java.lang.String id) |
Creates a new
GeneProduct element and adds it to the listOfGeneProducts list. |
Objective |
createObjective() |
Creates a new
Objective element and adds it to the
listOfObjectives . |
Objective |
createObjective(java.lang.String id) |
Creates a new
Objective element and adds it to the
listOfObjectives . |
Objective |
createObjective(java.lang.String id,
java.lang.String name,
Objective.Type type) |
Creates a new
Objective element and adds it to the
listOfObjectives . |
Objective |
createObjective(java.lang.String id,
Objective.Type type) |
Creates a new
Objective element and adds it to the
listOfObjectives . |
java.lang.String |
getActiveObjective() |
Gets the
activeObjective . |
Objective |
getActiveObjectiveInstance() |
|
boolean |
getAllowsChildren() |
|
javax.swing.tree.TreeNode |
getChildAt(int index) |
|
int |
getChildCount() |
|
FluxBound |
getFluxBound(int i) |
Deprecated.
Only defined in FBC version 1.
|
int |
getFluxBoundCount() |
Deprecated.
Only defined in FBC version 1.
|
GeneProduct |
getGeneProduct(int i) |
Gets an element from the
listOfGeneProducts at the given index. |
GeneProduct |
getGeneProduct(java.lang.String geneProductId) |
Gets an element from the listOfGeneProducts, with the given id.
|
int |
getGeneProductCount() |
Returns the number of
GeneProduct s in this FBCModelPlugin . |
ListOf<FluxBound> |
getListOfFluxBounds() |
Deprecated.
Only defined in FBC version 1.
|
ListOf<GeneProduct> |
getListOfGeneProducts() |
Returns the
listOfGeneProducts . |
ListOfObjectives |
getListOfObjectives() |
Returns the
listOfObjectives . |
int |
getNumFluxBound() |
Deprecated.
Only defined in FBC version 1.
|
int |
getNumGeneProducts() |
Returns the number of
GeneProduct s in this FBCModelPlugin . |
int |
getNumObjective() |
Return the number of
Objective s in this FBCModelPlugin . |
Objective |
getObjective(int i) |
Gets an element from the listOfObjectives at the given index.
|
int |
getObjectiveCount() |
Return the number of
Objective in this FBCModelPlugin . |
Model |
getParent() |
|
Model |
getParentSBMLObject() |
Returns the parent
SBase object to which this plugin object connected. |
boolean |
getStrict() |
Returns the value of
strict . |
boolean |
isSetActiveObjective() |
|
boolean |
isSetListOfFluxBounds() |
Deprecated.
Only defined in FBC version 1.
|
boolean |
isSetListOfGeneProducts() |
Returns
true if listOfGeneProducts contains at least one element. |
boolean |
isSetListOfObjectives() |
Returns
true if listOfObjectives is not null . |
boolean |
isSetStrict() |
Returns whether
strict is set. |
boolean |
isStrict() |
Returns the value of
strict . |
boolean |
readAttribute(java.lang.String attributeName,
java.lang.String prefix,
java.lang.String value) |
Reads and sets the attribute if it is know from this
SBasePlugin . |
void |
removeFluxBound(int i) |
Deprecated.
Only defined in FBC version 1.
|
boolean |
removeFluxBound(FluxBound fluxBound) |
Deprecated.
Only defined in FBC version 1.
|
GeneProduct |
removeGeneProduct(int i) |
Removes an element from the listOfGeneProducts at the given index.
|
GeneProduct |
removeGeneProduct(java.lang.String geneProductId) |
Removes an element from the
listOfGeneProducts . |
boolean |
removeGeneProduct(GeneProduct geneProduct) |
Removes an element from the
listOfGeneProducts . |
void |
removeObjective(int i) |
Removes an element from the listOfObjectives at the given index.
|
boolean |
removeObjective(Objective objective) |
Removes an element from the listOfObjectives.
|
void |
setActiveObjective(java.lang.String activeObjective) |
The activeObjective refers to the id of an existing objective.
|
void |
setActiveObjective(Objective objective) |
|
void |
setListOfFluxBounds(ListOf<FluxBound> listOfFluxBounds) |
Deprecated.
Only defined in FBC version 1.
|
void |
setListOfGeneProducts(ListOf<GeneProduct> listOfGeneProducts) |
Sets the given
ListOf<GeneProduct> . |
void |
setListOfObjectives(ListOfObjectives listOfObjectives) |
Sets the given
ListOfObjectives . |
void |
setListOfObjectives(ListOf<Objective> listOfObjectives) |
Sets the given
ListOf<Objective> . |
void |
setNotesKeyToUserObject(java.lang.String key) |
|
void |
setStrict(boolean strict) |
Sets the value of strict
|
boolean |
unsetListOfFluxBounds() |
Deprecated.
Only defined in FBC version 1.
|
boolean |
unsetListOfGeneProducts() |
|
boolean |
unsetListOfObjectives() |
Returns
true if listOfObjectives contain at least one element,
otherwise false |
boolean |
unsetStrict() |
Unsets the variable strict.
|
java.util.Map<java.lang.String,java.lang.String> |
writeXMLAttributes() |
Returns a
Map containing the XML attributes of this object. |
getPackageName, getPrefix, getURI
equals, fireNodeAddedEvent, fireNodeRemovedEvent, firePropertyChange, getElementNamespace, getExtendedSBase, getLevel, getPackageVersion, getSBMLDocument, getVersion, hashCode, isSetExtendedSBase, isSetPackageVersion, removeFromParent, setExtendedSBase, setNamespace, setPackageVersion
addAllChangeListeners, addAllChangeListeners, addTreeNodeChangeListener, addTreeNodeChangeListener, children, clearUserObjects, containsUserObjectKey, filter, filter, filter, getIndex, getListOfTreeNodeChangeListeners, getNumChildren, getRoot, getTreeNodeChangeListenerCount, getUserObject, indexOf, isLeaf, isRoot, isSetParent, isSetUserObjects, putUserObject, removeAllTreeNodeChangeListeners, removeAllTreeNodeChangeListeners, removeTreeNodeChangeListener, removeTreeNodeChangeListener, removeUserObject, setParent, toString, userObjectKeySet
addAllChangeListeners, addAllChangeListeners, addTreeNodeChangeListener, addTreeNodeChangeListener, clearUserObjects, containsUserObjectKey, filter, filter, filter, getListOfTreeNodeChangeListeners, getRoot, getTreeNodeChangeListenerCount, getUserObject, isRoot, isSetParent, isSetUserObjects, putUserObject, removeAllTreeNodeChangeListeners, removeAllTreeNodeChangeListeners, removeTreeNodeChangeListener, removeTreeNodeChangeListener, removeUserObject, userObjectKeySet
public FBCModelPlugin(FBCModelPlugin fbcPlugin)
fbcPlugin
- the instance to clonepublic FBCModelPlugin(Model model)
FBCModelPlugin
instance.model
- the core Model
@Deprecated public boolean addFluxBound(FluxBound fluxBound)
FluxBound
to the listOfFluxBounds.
The listOfFluxBounds is initialized if necessary.
fluxBound
- the element to add to the listtrue
(as specified by Collection.add(E)
)public boolean addGeneProduct(GeneProduct geneProduct)
GeneProduct
to the listOfGeneProducts
.
The listOfGeneProducts is initialized if necessary.
geneProduct
- the element to add to the listtrue
(as specified by Collection.add(E)
)Collection.add(Object)
public boolean addObjective(Objective objective)
Objective
to the listOfObjectives.
The listOfObjectives is initialized if necessary.
objective
- the element to add to the listtrue
(as specified by Collection.add(E)
)public FBCModelPlugin clone()
SBasePlugin
SBasePlugin
from this SBasePlugin
.clone
in interface SBasePlugin
clone
in class AbstractSBasePlugin
SBasePlugin
from this SBasePlugin
.@Deprecated public FluxBound createFluxBound()
FluxBound
element and adds it to the listOfFluxBounds
list.FluxBound
element@Deprecated public FluxBound createFluxBound(java.lang.String id)
FluxBound
element and adds it to the ListOfFluxBounds listid
- the idFluxBound
elementpublic GeneProduct createGeneProduct()
GeneProduct
element and adds it to the ListOfGeneProducts list.GeneProduct
elementpublic GeneProduct createGeneProduct(java.lang.String id)
GeneProduct
element and adds it to the listOfGeneProducts
list.id
- the idGeneProduct
element.public Objective createObjective()
Objective
element and adds it to the
listOfObjectives
.Objective
element or null
if the
operation fails.createObjective(String)
public Objective createObjective(java.lang.String id)
Objective
element and adds it to the
listOfObjectives
.id
- the identifier for the Objective
of type SId, can be
null
.Objective
element or null
if the
operation fails.createObjective(String, Objective.Type)
public Objective createObjective(java.lang.String id, Objective.Type type)
Objective
element and adds it to the
listOfObjectives
.id
- the identifier for the Objective
of type SId, can be
null
.type
- the type of the Objective
, i.e., maximize or minimize.Objective
element or null
if the
operation fails.createObjective(String, String, Objective.Type)
public Objective createObjective(java.lang.String id, java.lang.String name, Objective.Type type)
Objective
element and adds it to the
listOfObjectives
.public java.lang.String getActiveObjective()
activeObjective
.
If the activeObjective
is not defined, an empty String is returned.
activeObjective
or "".public Objective getActiveObjectiveInstance()
public boolean getAllowsChildren()
public javax.swing.tree.TreeNode getChildAt(int index)
public int getChildCount()
@Deprecated public FluxBound getFluxBound(int i)
i
- the index where to get the FluxBound
java.lang.IndexOutOfBoundsException
- if the index is out of bound (index < 0 || index > list.size)@Deprecated public int getFluxBoundCount()
FluxBound
in this FBCModelPlugin
.FluxBound
in this FBCModelPlugin
.public GeneProduct getGeneProduct(int i)
listOfGeneProducts
at the given index.i
- the index of the GeneProduct
element to get.java.lang.IndexOutOfBoundsException
- if the listOf is not set or
if the index is out of bound (index < 0 || index > list.size)public GeneProduct getGeneProduct(java.lang.String geneProductId)
geneProductId
- the id of the GeneProduct
element to get.null
.public int getGeneProductCount()
GeneProduct
s in this FBCModelPlugin
.GeneProduct
s in this FBCModelPlugin
.@Deprecated public ListOf<FluxBound> getListOfFluxBounds()
public ListOf<GeneProduct> getListOfGeneProducts()
listOfGeneProducts
. Creates it if it is not already existing.listOfGeneProducts
.public ListOfObjectives getListOfObjectives()
listOfObjectives
. Creates it if it is not already
existing.@Deprecated public int getNumFluxBound()
FluxBound
in this FBCModelPlugin
.FluxBound
in this FBCModelPlugin
.getFluxBoundCount()
public int getNumGeneProducts()
GeneProduct
s in this FBCModelPlugin
.GeneProduct
s in this FBCModelPlugin
.getGeneProductCount()
public int getNumObjective()
Objective
s in this FBCModelPlugin
.Objective
s in this FBCModelPlugin
.getObjectiveCount()
public Objective getObjective(int i)
i
- the index where to get the Objective
java.lang.IndexOutOfBoundsException
- if the index is out of bound (index < 0 || index > list.size)public int getObjectiveCount()
Objective
in this FBCModelPlugin
.Objective
in this FBCModelPlugin
.public Model getParent()
getParent
in interface javax.swing.tree.TreeNode
getParent
in class AbstractTreeNode
public Model getParentSBMLObject()
SBasePlugin
SBase
object to which this plugin object connected.getParentSBMLObject
in interface SBasePlugin
getParentSBMLObject
in class AbstractSBasePlugin
SBase
object to which this plugin object connected.public boolean isSetActiveObjective()
@Deprecated public boolean isSetListOfFluxBounds()
true
if listOfFluxBounds contains at least one element.true
if listOfFluxBounds contains at least one element,
otherwise false
public boolean isSetListOfGeneProducts()
true
if listOfGeneProducts
contains at least one element.true
if listOfGeneProducts
contains at least one element,
otherwise false
.public boolean isSetListOfObjectives()
true
if listOfObjectives is not null
.true
if listOfObjectives is not null,
otherwise false
public boolean isSetStrict()
strict
is set.strict
is set.public boolean readAttribute(java.lang.String attributeName, java.lang.String prefix, java.lang.String value)
SBasePlugin
SBasePlugin
.attributeName
- localName of the XML attributeprefix
- prefix of the XML attributevalue
- value of the XML attributetrue
if the attribute has been successfully read.@Deprecated public boolean removeFluxBound(FluxBound fluxBound)
fluxBound
- the element to be removed from the listtrue
if the list contained the specified elementList.remove(Object)
@Deprecated public void removeFluxBound(int i)
i
- the index where to remove the FluxBound
java.lang.IndexOutOfBoundsException
- if the listOf is not set or
if the index is out of bound (index < 0 || index > list.size)public boolean removeGeneProduct(GeneProduct geneProduct)
listOfGeneProducts
.geneProduct
- the element to be removed from the list.true
if the list contained the specified element and it was removed.List.remove(Object)
public GeneProduct removeGeneProduct(int i)
i
- the index where to remove the GeneProduct
.java.lang.IndexOutOfBoundsException
- if the listOf is not set or
if the index is out of bound (index < 0 || index > list.size)public GeneProduct removeGeneProduct(java.lang.String geneProductId)
listOfGeneProducts
.geneProductId
- the id of the element to be removed from the list.null
.public void removeObjective(int i)
i
- the index where to remove the Objective
java.lang.IndexOutOfBoundsException
- if the listOf is not set or
if the index is out of bound (index < 0 || index > list.size)public boolean removeObjective(Objective objective)
objective
- the element to be removed from the listtrue
if the list contained the specified elementList.remove(Object)
public void setActiveObjective(Objective objective)
objective
- public void setActiveObjective(java.lang.String activeObjective)
activeObjective
- @Deprecated public void setListOfFluxBounds(ListOf<FluxBound> listOfFluxBounds)
ListOf<FluxBound>
. If listOfFluxBounds was defined before and contained some elements, they are all unset.
listOfFluxBounds
- public void setListOfGeneProducts(ListOf<GeneProduct> listOfGeneProducts)
ListOf<GeneProduct>
. If listOfGeneProducts
was defined before and contains some elements, they are all unset.listOfGeneProducts
- public void setListOfObjectives(ListOf<Objective> listOfObjectives)
ListOf<Objective>
.
If the given list is an instance of ListOfObjectives
, a call of
this method is identical to directly calling
setListOfObjectives(ListOfObjectives)
.
Otherwise, a new ListOfObjectives
will be created from the given
ListOf
.
Note that in the second case there is no active objective defined.
listOfObjectives
- public void setListOfObjectives(ListOfObjectives listOfObjectives)
ListOfObjectives
. If listOfObjectives was defined before and contained some elements, they are all unset.
listOfObjectives
- public void setNotesKeyToUserObject(java.lang.String key)
key
- public void setStrict(boolean strict)
strict
- the value of strict to be set.@Deprecated public boolean unsetListOfFluxBounds()
true
if listOfFluxBounds
contain at least one
element, otherwise false
public boolean unsetListOfGeneProducts()
true
if listOfGeneProducts
contains at least one element,
otherwise false
.public boolean unsetListOfObjectives()
true
if listOfObjectives contain at least one element,
otherwise false
true
if listOfObjectives contain at least one element,
otherwise false
public boolean unsetStrict()
true
if strict was set before, otherwise false
.public java.util.Map<java.lang.String,java.lang.String> writeXMLAttributes()
SBasePlugin
Map
containing the XML attributes of this object.writeXMLAttributes
in interface SBasePlugin
writeXMLAttributes
in class AbstractSBasePlugin
Map
containing the XML attributes of this object.