|
libSBML C# API
libSBML 5.10.0 C# API
|
{core}
An interface to an XML input stream.Public Member Functions | |
| long | determineNumberChildren (string elementName) |
| Analyses the tokens in the stream and returns the number of child tokens of the given element. More... | |
| long | determineNumberChildren () |
| Analyses the tokens in the stream and returns the number of child tokens of the given element. More... | |
| long | determineNumSpecificChildren (string childName, string container) |
| Analyses the tokens in the stream and returns the number of child tokens of the specified type within the given element. More... | |
| virtual void | Dispose () |
| string | getEncoding () |
| Returns the encoding of the XML stream. More... | |
| XMLErrorLog | getErrorLog () |
| Returns an XMLErrorLog which can be used to log XML parse errors and other validation errors (and messages). More... | |
| SBMLNamespaces | getSBMLNamespaces () |
| Returns the SBMLNamespaces object attached to this XMLInputStream if it has been set, null otherwise. More... | |
| string | getVersion () |
| Returns the version of the XML stream. More... | |
| bool | isEOF () |
| Returns true if end of file (stream) has been reached, false otherwise. More... | |
| bool | isError () |
| Returns true if a fatal error occurred while reading from this stream. More... | |
| bool | isGood () |
| Returns true if the stream is in a good state (i.e. More... | |
| XMLToken | next () |
| Consumes the next XMLToken and return it. More... | |
| XMLToken | peek () |
| Returns the next XMLToken without consuming it. More... | |
| int | setErrorLog (XMLErrorLog log) |
| Sets the XMLErrorLog this stream will use to log errors. More... | |
| void | setSBMLNamespaces (SBMLNamespaces sbmlns) |
| Sets the SBMLNamespaces object to allow this stream to reference the available SBML namespaces being read. More... | |
| void | skipPastEnd (XMLToken element) |
| Consume zero or more XMLTokens up to and including the corresponding end XML element or EOF. More... | |
| void | skipText () |
| Consume zero or more XMLTokens up to but not including the next XML element or EOF. More... | |
| string | toString () |
| Prints a string representation of the underlying token stream, for debugging purposes. More... | |
| XMLInputStream (string content, bool isFile, string library, XMLErrorLog errorLog) | |
| Creates a new XMLInputStream. More... | |
| XMLInputStream (string content, bool isFile, string library) | |
| Creates a new XMLInputStream. More... | |
| XMLInputStream (string content, bool isFile) | |
| Creates a new XMLInputStream. More... | |
| XMLInputStream (string content) | |
| Creates a new XMLInputStream. More... | |
Protected Attributes | |
| bool | swigCMemOwn |
| libsbmlcs.XMLInputStream.XMLInputStream | ( | string | content, |
| bool | isFile, | ||
| string | library, | ||
| XMLErrorLog | errorLog | ||
| ) |
Creates a new XMLInputStream.
content the source of the stream.
isFile bool flag to indicate whether content is a file name. If true, content is assumed to be the file from which the XML content is to be read. If false, content is taken to be a string that is the content to be read.
library the name of the parser library to use.
errorLog the XMLErrorLog object to use.
| libsbmlcs.XMLInputStream.XMLInputStream | ( | string | content, |
| bool | isFile, | ||
| string | library | ||
| ) |
Creates a new XMLInputStream.
content the source of the stream.
isFile bool flag to indicate whether content is a file name. If true, content is assumed to be the file from which the XML content is to be read. If false, content is taken to be a string that is the content to be read.
library the name of the parser library to use.
errorLog the XMLErrorLog object to use.
| libsbmlcs.XMLInputStream.XMLInputStream | ( | string | content, |
| bool | isFile | ||
| ) |
Creates a new XMLInputStream.
content the source of the stream.
isFile bool flag to indicate whether content is a file name. If true, content is assumed to be the file from which the XML content is to be read. If false, content is taken to be a string that is the content to be read.
library the name of the parser library to use.
errorLog the XMLErrorLog object to use.
| libsbmlcs.XMLInputStream.XMLInputStream | ( | string | content | ) |
Creates a new XMLInputStream.
content the source of the stream.
isFile bool flag to indicate whether content is a file name. If true, content is assumed to be the file from which the XML content is to be read. If false, content is taken to be a string that is the content to be read.
library the name of the parser library to use.
errorLog the XMLErrorLog object to use.
| long libsbmlcs.XMLInputStream.determineNumberChildren | ( | string | elementName | ) |
Analyses the tokens in the stream and returns the number of child tokens of the given element.
| elementName | a string representing the name of the element for which the number of children are to be determined. |
This function allows information from the input stream to be determined without the need to actually read and consume the tokens in the stream. This functionality is particularly utilized when reading MathML.
The function will return the number of child elements of the element represented by the elementName supplied, i.e. the number of child elements encountered before the closing tag for the elementname supplied. If the elementName has not been supplied then the function assumes that it is reading an apply element followed by a function element.
| long libsbmlcs.XMLInputStream.determineNumberChildren | ( | ) |
Analyses the tokens in the stream and returns the number of child tokens of the given element.
| elementName | a string representing the name of the element for which the number of children are to be determined. |
This function allows information from the input stream to be determined without the need to actually read and consume the tokens in the stream. This functionality is particularly utilized when reading MathML.
The function will return the number of child elements of the element represented by the elementName supplied, i.e. the number of child elements encountered before the closing tag for the elementname supplied. If the elementName has not been supplied then the function assumes that it is reading an apply element followed by a function element.
| long libsbmlcs.XMLInputStream.determineNumSpecificChildren | ( | string | childName, |
| string | container | ||
| ) |
Analyses the tokens in the stream and returns the number of child tokens of the specified type within the given element.
| childName | a string representing the name of the child element whose number is to be determined. |
| container | a string representing the name of the element for which the number of children are to be determined. |
This function allows information from the input stream to be determined without the need to actually read and consume the tokens in the stream. This functionality is particularly utilized when reading MathML.
The function will return the number of child elements of the element represented by the childName supplied within the element specified by the container, i.e. the number of child elements encountered before the closing tag for the container supplied.
|
virtual |
| string libsbmlcs.XMLInputStream.getEncoding | ( | ) |
Returns the encoding of the XML stream.
| XMLErrorLog libsbmlcs.XMLInputStream.getErrorLog | ( | ) |
Returns an XMLErrorLog which can be used to log XML parse errors and other validation errors (and messages).
| SBMLNamespaces libsbmlcs.XMLInputStream.getSBMLNamespaces | ( | ) |
Returns the SBMLNamespaces object attached to this XMLInputStream if it has been set, null otherwise.
| string libsbmlcs.XMLInputStream.getVersion | ( | ) |
Returns the version of the XML stream.
| bool libsbmlcs.XMLInputStream.isEOF | ( | ) |
Returns true if end of file (stream) has been reached, false otherwise.
| bool libsbmlcs.XMLInputStream.isError | ( | ) |
Returns true if a fatal error occurred while reading from this stream.
| bool libsbmlcs.XMLInputStream.isGood | ( | ) |
| XMLToken libsbmlcs.XMLInputStream.next | ( | ) |
Consumes the next XMLToken and return it.
| XMLToken libsbmlcs.XMLInputStream.peek | ( | ) |
Returns the next XMLToken without consuming it.
A subsequent call to either peek() or next() will return the same token.
| int libsbmlcs.XMLInputStream.setErrorLog | ( | XMLErrorLog | log | ) |
Sets the XMLErrorLog this stream will use to log errors.
| void libsbmlcs.XMLInputStream.setSBMLNamespaces | ( | SBMLNamespaces | sbmlns | ) |
Sets the SBMLNamespaces object to allow this stream to reference the available SBML namespaces being read.
| void libsbmlcs.XMLInputStream.skipPastEnd | ( | XMLToken | element | ) |
Consume zero or more XMLTokens up to and including the corresponding end XML element or EOF.
| void libsbmlcs.XMLInputStream.skipText | ( | ) |
Consume zero or more XMLTokens up to but not including the next XML element or EOF.
| string libsbmlcs.XMLInputStream.toString | ( | ) |
Prints a string representation of the underlying token stream, for debugging purposes.
|
protected |