Rudiments
Public Member Functions
xmldom Class Reference

Inherits xmlsax.

List of all members.

Public Member Functions

 xmldom ()
virtual ~xmldom ()
bool parseFile (const char *filename)
bool parseString (const char *string)
xmldomnodegetRootNode () const
void createRootNode ()
bool writeFile (const char *filename, mode_t perms) const
- Public Member Functions inherited from xmlsax
 xmlsax ()
virtual ~xmlsax ()
const char * getError ()

Additional Inherited Members

- Protected Member Functions inherited from xmlsax
virtual bool tagStart (const char *name)
virtual bool attributeName (const char *name)
virtual bool attributeValue (const char *value)
virtual bool text (const char *string)
virtual bool tagEnd (const char *name)
virtual bool comment (const char *string)
virtual bool cdata (const char *string)

Detailed Description

The xmldom class implements a minimal XML DOM parser.


Constructor & Destructor Documentation

xmldom::xmldom ( )

Creates a new instance of the xmldom class.

virtual xmldom::~xmldom ( )
virtual

Deletes this instance of the xmldom class.


Member Function Documentation

void xmldom::createRootNode ( )

Creates a new root node. This is useful for building a tree from scratch.

xmldomnode* xmldom::getRootNode ( ) const

Returns the root node of the DOM tree.

bool xmldom::parseFile ( const char *  filename)

Parses file "filename" and generates a DOM tree.

Reimplemented from xmlsax.

bool xmldom::parseString ( const char *  string)

Parses string "string" and generates a DOM tree.

Reimplemented from xmlsax.

bool xmldom::writeFile ( const char *  filename,
mode_t  perms 
) const

Writes the current DOM tree to "filename" and sets permissions of the file to "perms".