libSBML Perl API
libSBML 5.17.2 Perl API
|
{core}
Base class for extending SBML objects in packages.This class of objects is defined by libSBML only and has no direct equivalent in terms of SBML components. This class is not prescribed by the SBML specifications, although it is used to implement features defined in SBML.
The SBasePlugin class is libSBML's base class for extensions of core SBML component objects. SBasePlugin defines basic virtual methods for reading/writing/checking additional attributes and/or subobjects; these methods should be overridden by subclasses to implement the necessary features of an extended SBML object.
Public Member Functions | |
virtual SBasePlugin * | clone () const |
Creates and returns a deep copy of this SBasePlugin object. More... | |
virtual List * | getAllElements (ElementFilter *filter=NULL) |
Returns all child objects of this object. More... | |
virtual SBase * | getElementByMetaId (const std::string &metaid) |
Return the first child object found with a given meta identifier. More... | |
virtual SBase * | getElementBySId (const std::string &id) |
Return the first child object found with a given identifier. More... | |
const std::string & | getElementNamespace () const |
Returns the namespace URI of the package to which this plugin object belongs. More... | |
unsigned int | getLevel () const |
Returns the SBML Level of the package extension of this plugin object. More... | |
const std::string & | getPackageName () const |
Returns the short-form name of the package to which this plugin object belongs. More... | |
unsigned int | getPackageVersion () const |
Returns the package version of the package extension of this plugin object. More... | |
SBase * | getParentSBMLObject () |
Returns the parent object to which this plugin object is connected. More... | |
const SBase * | getParentSBMLObject () const |
Returns the parent object to which this plugin object is connected. More... | |
const std::string & | getPrefix () const |
Returns the XML namespace prefix of the package to which this plugin object belongs. More... | |
SBMLDocument * | getSBMLDocument () |
Returns the SBMLDocument object containing this object instance. More... | |
const SBMLDocument * | getSBMLDocument () const |
Returns the SBMLDocument object containing this object instance. More... | |
std::string | getURI () const |
Returns the XML namespace URI for the package to which this object belongs. More... | |
unsigned int | getVersion () const |
Returns the Version within the SBML Level of the package extension of this plugin object. More... | |
virtual bool | isValidTypeForList (SBase *item) const |
SBasePlugin & | operator= (const SBasePlugin &orig) |
Assignment operator for SBasePlugin. More... | |
virtual void | renameMetaIdRefs (const std::string &oldid, const std::string &newid) |
virtual void | renameSIdRefs (const std::string &oldid, const std::string &newid) |
virtual void | renameUnitSIdRefs (const std::string &oldid, const std::string &newid) |
int | setElementNamespace (const std::string &uri) |
Sets the XML namespace to which this object belongs. More... | |
virtual | ~SBasePlugin () |
Destroy this SBasePlugin object. More... | |
|
virtual |
Destroy this SBasePlugin object.
|
virtual |
Creates and returns a deep copy of this SBasePlugin object.
Reimplemented in FbcModelPlugin, CompSBMLDocumentPlugin, CompModelPlugin, CompSBasePlugin, SBMLDocumentPlugin, FbcSpeciesPlugin, RenderSBMLDocumentPlugin, MultiCompartmentPlugin, FbcReactionPlugin, GroupsModelPlugin, LayoutSBMLDocumentPlugin, GroupsSBMLDocumentPlugin, QualSBMLDocumentPlugin, FbcSBMLDocumentPlugin, LayoutModelPlugin, QualModelPlugin, LayoutSpeciesReferencePlugin, MultiSpeciesPlugin, MultiSpeciesReferencePlugin, MultiModelPlugin, MultiSBMLDocumentPlugin, MultiSimpleSpeciesReferencePlugin, MultiListOfReactionsPlugin, RenderLayoutPlugin, RenderListOfLayoutsPlugin, and RenderGraphicalObjectPlugin.
|
virtual |
Returns all child objects of this object.
This returns a List object containing all child SBase objects of this one, at any nesting depth. Optionally, callers can supply a filter that will establish the search criteria for matching objects.
filter | a pointer to an ElementFilter, which causes the function to return only elements that match a particular set of constraints. If NULL (the default), the function will return all child objects. |
Reimplemented in GroupsModelPlugin, FbcModelPlugin, MultiCompartmentPlugin, MultiSpeciesPlugin, LayoutModelPlugin, MultiSimpleSpeciesReferencePlugin, RenderListOfLayoutsPlugin, FbcReactionPlugin, CompModelPlugin, CompSBasePlugin, CompSBMLDocumentPlugin, RenderLayoutPlugin, MultiSpeciesReferencePlugin, MultiModelPlugin, and QualModelPlugin.
|
virtual |
Return the first child object found with a given meta identifier.
This method searches all the subobjects under this one, compares their meta identifiers to metaid
, and returns the first one that machines.
metaid | string, the metaid of the object to find. |
metaid
. Reimplemented in QualModelPlugin, GroupsModelPlugin, CompModelPlugin, CompSBasePlugin, and CompSBMLDocumentPlugin.
|
virtual |
Return the first child object found with a given identifier.
This method searches all the subobjects under this one, compares their identifiers to id
, and returns the first one that machines.
Normally, SId
type identifier values are unique across a model in SBML. However, in some circumstances they may not be, such as if a model is invalid because of multiple objects having the same identifier.
id | string representing the identifier of the object to find. |
id
. Reimplemented in QualModelPlugin, GroupsModelPlugin, CompModelPlugin, CompSBasePlugin, and CompSBMLDocumentPlugin.
const std::string & SBasePlugin::getElementNamespace | ( | ) | const |
Returns the namespace URI of the package to which this plugin object belongs.
unsigned int SBasePlugin::getLevel | ( | ) | const |
Returns the SBML Level of the package extension of this plugin object.
const std::string & SBasePlugin::getPackageName | ( | ) | const |
Returns the short-form name of the package to which this plugin object belongs.
unsigned int SBasePlugin::getPackageVersion | ( | ) | const |
Returns the package version of the package extension of this plugin object.
SBase * SBasePlugin::getParentSBMLObject | ( | ) |
Returns the parent object to which this plugin object is connected.
const SBase * SBasePlugin::getParentSBMLObject | ( | ) | const |
Returns the parent object to which this plugin object is connected.
const std::string & SBasePlugin::getPrefix | ( | ) | const |
Returns the XML namespace prefix of the package to which this plugin object belongs.
SBMLDocument * SBasePlugin::getSBMLDocument | ( | ) |
Returns the SBMLDocument object containing this object instance.
This method allows the caller to obtain the SBMLDocument for the current object.
const SBMLDocument * SBasePlugin::getSBMLDocument | ( | ) | const |
Returns the SBMLDocument object containing this object instance.
This method allows the caller to obtain the SBMLDocument for the current object.
std::string SBasePlugin::getURI | ( | ) | const |
Returns the XML namespace URI for the package to which this object belongs.
"http://www.sbml.org/sbml/level3/version1/core"
. Individual SBML Level 3 packages define their own XML namespaces; for example, all elements belonging to the SBML Level 3 Layout Version 1 package must be placed in the XML namespace "http://www.sbml.org/sbml/level3/version1/layout/version1/"
.This method first looks into the SBMLNamespaces object possessed by the parent SBMLDocument object of the current object. If this cannot be found, this method returns the result of getElementNamespace().
unsigned int SBasePlugin::getVersion | ( | ) | const |
Returns the Version within the SBML Level of the package extension of this plugin object.
|
virtual |
SBasePlugin & SBasePlugin::operator= | ( | const SBasePlugin & | orig | ) |
Assignment operator for SBasePlugin.
orig | the object whose values are used as the basis of the assignment. |
|
virtual |
|
virtual |
Reimplemented in FbcReactionPlugin.
|
virtual |
int SBasePlugin::setElementNamespace | ( | const std::string & | uri | ) |
Sets the XML namespace to which this object belongs.
"http://www.sbml.org/sbml/level3/version1/core"
. Individual SBML Level 3 packages define their own XML namespaces; for example, all elements belonging to the SBML Level 3 Layout Version 1 package must be placed in the XML namespace "http://www.sbml.org/sbml/level3/version1/layout/version1/"
.uri | the URI to assign to this object. |