NXmlReader Class Reference

NXmlReader class is used to read xml documents. More...

List of all members.

Public Member Functions

 NXmlReader (void)
 Constructs a NXmlReader object.
 ~NXmlReader (void)
 Destroys a NXmlReader object.
void setSchema (NXmlAbstractParser::XmlSchema schema)
 Sets the data definition schema used for parsing the document.
NXmlAbstractParser::XmlSchema getSchema (void) const
 Gets the data defintion schema used for parsing the document.
void setEncoding (const NString &encoding)
 Sets the encoding of the document.
NString getEncoding (void) const
 Gets the encoding of the document.
void setDefinitionUrl (const NString &url)
 Sets the path/url to the data definition schema.
NString getDefinitionUrl (void) const
 Gets the path/url to the data definition schema.
void load (const NString &path)
 Load a xml document.
void load (const NString &buffer, nint32 size)
 Load a xml document.
void load (const NFile *file)
 Load a xml document.
NXmlDocumentgetDocument (void)
 Gets a NXmlDocument containing the parsed xml data.


Detailed Description

NXmlReader class is used to read xml documents.
Examples:

xmlreader.cpp, and xmlreader.h.

Definition at line 48 of file nxmlreader.h.


Member Function Documentation

NXmlAbstractParser::XmlSchema getSchema ( void   )  const

Gets the data defintion schema used for parsing the document.

Returns:
The data definition schema used for parsing the document

Definition at line 68 of file nxmlreader.cpp.

void setEncoding ( const NString encoding  ) 

Sets the encoding of the document.

Parameters:
encoding The encoding of the document
Note:
Param encoding is not used if file is parsed against a dtd or schema

Definition at line 73 of file nxmlreader.cpp.

NString getEncoding ( void   )  const

Gets the encoding of the document.

Returns:
The name of the encoding of the document

Definition at line 78 of file nxmlreader.cpp.

void setDefinitionUrl ( const NString url  ) 

Sets the path/url to the data definition schema.

Parameters:
url The path to the data definition schema

Definition at line 82 of file nxmlreader.cpp.

NString getDefinitionUrl ( void   )  const

Gets the path/url to the data definition schema.

Returns:
The path/url to the data definition schema

Definition at line 87 of file nxmlreader.cpp.

void load ( const NString path  ) 

Load a xml document.

Parameters:
path The path of a file containing a xml document

Definition at line 105 of file nxmlreader.cpp.

References NXmlAbstractParser::parse(), NXmlAbstractParser::setDefinitionUrl(), NXmlAbstractParser::XMLDTD, NXmlAbstractParser::XMLNOPARSING, and NXmlAbstractParser::XMLSCHEMA.

void load ( const NString buffer,
nint32  size 
)

Load a xml document.

Parameters:
buffer An in memory buffer containing a xml document
size The size of the buffer

Definition at line 152 of file nxmlreader.cpp.

References NXmlAbstractParser::parse(), NXmlAbstractParser::setDefinitionUrl(), NXmlAbstractParser::XMLDTD, NXmlAbstractParser::XMLNOPARSING, and NXmlAbstractParser::XMLSCHEMA.

void load ( const NFile file  ) 

Load a xml document.

Parameters:
file An open NFile object containing a xml document

Definition at line 199 of file nxmlreader.cpp.

References NXmlAbstractParser::parse(), NXmlAbstractParser::setDefinitionUrl(), NXmlAbstractParser::XMLDTD, NXmlAbstractParser::XMLNOPARSING, and NXmlAbstractParser::XMLSCHEMA.

NXmlDocument * getDocument ( void   ) 

Gets a NXmlDocument containing the parsed xml data.

Returns:
A NXmlDocument object containing the parsed xml data

Definition at line 92 of file nxmlreader.cpp.


The documentation for this class was generated from the following files:
Generated on Wed Mar 5 23:10:37 2008 for NemesisUtilitiesSystem by  doxygen 1.5.4