Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   Related Pages  

rdXMLDocument Class Reference

A class for managing and for performing operations on an XML document. More...

#include <rdXMLDocument.h>

List of all members.

Public Member Functions

virtual ~rdXMLDocument ()
 Handle delete of an rdXMLDocument object.

 rdXMLDocument ()
 Construct a rdXMLDocument object with a locally generated IDOM_Document.

 rdXMLDocument (const char *aFileName)
 Construct an rdXMLDocument object from an XML file.

 rdXMLDocument (const rdXMLDocument &aDocument)
 Construct a copy of an rdXMLDocument object.

IDOM_Document * getIDOMDocument () const
 Get the XML document.

void print (const char *aFileName=NULL)
 Print the XML document to file.


Static Public Attributes

const XMLCh UTF8 []

Private Member Functions

void setNull ()
 Set NULL values for all member variables.

void printDeclaration ()
 Print the XML document declaration.


Static Private Member Functions

void CreateFormatter (ostream *aOstream=&cout)
 Initialize a formatter for the document.


Private Attributes

IDOMParser * _parser
 XML parser.

IDOM_Document * _document
 XML document.


Detailed Description

A class for managing and for performing operations on an XML document.

The document can originate from one of two sources: 1) parsed from an XML source or 2) created locally in memory.

This product includes software developed by the Apache Software Foundation (http://www.apache.org/).

Version:
1.0
Author:
Frank C. Anderson


Constructor & Destructor Documentation

rdXMLDocument::rdXMLDocument  ) 
 

Construct a rdXMLDocument object with a locally generated IDOM_Document.

This constructor is used when an XML document is going to be generated locally in memory without reference to an XML file. The initial IDOM_Document is empty.

rdXMLDocument::rdXMLDocument const char *  aFileName  ) 
 

Construct an rdXMLDocument object from an XML file.

A parser is created for the purpose of reading in the XML file.

rdXMLDocument::rdXMLDocument const rdXMLDocument &  aDocument  ) 
 

Construct a copy of an rdXMLDocument object.

The document an all its nodes are copied; however, the parser associated with the copied document, if any, is not copied.


Member Function Documentation

void rdXMLDocument::CreateFormatter ostream *  aOstream = &cout  )  [static, private]
 

Initialize a formatter for the document.

This method creates a formatter that is used by all documents for printing.

IDOM_Document * rdXMLDocument::getIDOMDocument  )  const
 

Get the XML document.

Note that the returned document, and any of its child nodes, should never be deleted by the caller. The document and resources associated with the document will be deleted when this rdXMLDocument object is deleted.

Returns:
Document, or NULL if no document has been generated.


Member Data Documentation

const XMLCh rdXMLDocument::UTF8 [static]
 

Initial value:

 {
   chLatin_U, chLatin_T, chLatin_F, chDash, chDigit_8, 0 }


The documentation for this class was generated from the following files:
Generated on Wed Aug 20 02:17:13 2003 for Simulation Software by doxygen1.3