libSBML Python API  5.10.0
 All Classes Namespaces Files Functions Variables Modules Pages
libsbml.SBMLFileResolver Class Reference
Inheritance diagram for libsbml.SBMLFileResolver:
[legend]

Detailed Description

{comp}

comp A resolver for documents stored on a file system.

This class of objects is defined by libSBML only and has no direct equivalent in terms of SBML components. It is a class used in the implementation of extra functionality provided by libSBML.

In SBML, resolvers come into play with the SBML Level 3 Hierarchical Model Composition package (“comp”); this package includes features that allow a model to be composed from pieces that are external to a given SBML document, which implies the need to be able to identify and locate those external pieces. The identifiers used in “comp” are URIs (Uniform Resource Identifiers).

SBMLFileResolver is a class implementing the ability to resolve URIs to files. It works on the local file system only. It can resolve relative and absolute paths, and directories to be searched can be specified using the methodsSBMLFileResolver.addAdditionalDir() and SBMLFileResolver.clearAdditionalDirs().

See also
SBMLResolver
SBMLUri

Public Member Functions

def addAdditionalDir
 
def clearAdditionalDirs
 
def clone
 
def resolve
 
def resolveUri
 

Member Function Documentation

def libsbml.SBMLFileResolver.addAdditionalDir (   self,
  args 
)

Python method signature(s):

addAdditionalDir(SBMLFileResolver self, string dir)

Adds a directory to the list of directories to search for files to resolve.

Parameters
dirthe directory to add.
See also
clearAdditionalDirs()
def libsbml.SBMLFileResolver.clearAdditionalDirs (   self)

Python method signature(s):

clearAdditionalDirs(SBMLFileResolver self)

Removes the list of directories to search for files to resolve.

After this method is called, SBMLFileResolver.resolve() will only search absolute or relative directories. New directories can be added using SBMLFileResolver.addAdditionalDir().

See also
addAdditionalDir()
def libsbml.SBMLFileResolver.clone (   self)

{comp}

comp A resolver for documents stored on a file system.

This class of objects is defined by libSBML only and has no direct equivalent in terms of SBML components. It is a class used in the implementation of extra functionality provided by libSBML.

In SBML, resolvers come into play with the SBML Level 3 Hierarchical Model Composition package (“comp”); this package includes features that allow a model to be composed from pieces that are external to a given SBML document, which implies the need to be able to identify and locate those external pieces. The identifiers used in “comp” are URIs (Uniform Resource Identifiers).

SBMLFileResolver is a class implementing the ability to resolve URIs to files. It works on the local file system only. It can resolve relative and absolute paths, and directories to be searched can be specified using the methodsSBMLFileResolver.addAdditionalDir() and SBMLFileResolver.clearAdditionalDirs().

See also
SBMLResolver
SBMLUri Python method signature(s):
clone(SBMLFileResolver self)   SBMLFileResolver

Creates and returns a deep copy of this SBMLFileResolver object.

Returns
a (deep) copy of this SBMLFileResolver object.
def libsbml.SBMLFileResolver.resolve (   self,
  args 
)

Python method signature(s):

resolve(SBMLFileResolver self, string uri, string baseUri="")   SBMLDocument
resolve(SBMLFileResolver self, string uri)   SBMLDocument

Resolves the document for the given URI.

Parameters
urithe URI to the target document
baseUribase URI, in case the URI is a relative one
Returns
the document, if this resolver can resolve the document or None.
def libsbml.SBMLFileResolver.resolveUri (   self,
  args 
)

Python method signature(s):

resolveUri(SBMLFileResolver self, string uri, string baseUri="")   SBMLUri
resolveUri(SBMLFileResolver self, string uri)   SBMLUri

Resolves the full URI for a given URI without actually reading the document.

Parameters
urithe URI to the target document
baseUribase URI, in case the URI is a relative one
Returns
the full URI to the document, if this resolver can resolve the document or None.