NEDSAXHandler Class Reference
[XML Parsing]

SAX handler (to be used with SAXParser) that builds a NED object tree. More...

#include <nedsaxhandler.h>

Inheritance diagram for NEDSAXHandler:
SAXHandler

List of all members.

Public Member Functions

 NEDSAXHandler (const char *filename, NEDErrorStore *e)
virtual ~NEDSAXHandler ()
virtual NEDElementgetTree ()
SAX event handlers

virtual void startElement (const char *name, const char **atts)
virtual void endElement (const char *name)
virtual void characterData (const char *s, int len)
virtual void processingInstruction (const char *target, const char *data)
virtual void comment (const char *data)
virtual void startCdataSection ()
virtual void endCdataSection ()

Detailed Description

SAX handler (to be used with SAXParser) that builds a NED object tree.

Elements of the tree are subclassed from NEDElement; NEDElementFactory is used to actually create the objects.

Usage:

    NEDSAXHandler nedsaxhandler(filename);
    SAXParser parser;
    parser.setHandler(&nedsaxhandler);
    parser.parse(filename);
    NEDElement *result = nedsaxhandler.getTree();
 

Constructor & Destructor Documentation

NEDSAXHandler::NEDSAXHandler ( const char *  filename,
NEDErrorStore e 
)

Constructor.

Filename is necessary to create correct src-loc info.

virtual NEDSAXHandler::~NEDSAXHandler (  )  [virtual]

Destructor.


Member Function Documentation

virtual void NEDSAXHandler::characterData ( const char *  s,
int  len 
) [virtual]

Called by the parser on SAX CharacterData events.

Reimplemented from SAXHandler.

virtual void NEDSAXHandler::comment ( const char *  data  )  [virtual]

Called by the parser on SAX Comment events.

Reimplemented from SAXHandler.

virtual void NEDSAXHandler::endCdataSection (  )  [virtual]

Called by the parser on SAX CDataEnd events.

Reimplemented from SAXHandler.

virtual void NEDSAXHandler::endElement ( const char *  name  )  [virtual]

Called by the parser on SAX EndElement events.

Reimplemented from SAXHandler.

virtual NEDElement* NEDSAXHandler::getTree (  )  [virtual]

Returns the object tree that was built up during XML parsing.

virtual void NEDSAXHandler::processingInstruction ( const char *  target,
const char *  data 
) [virtual]

Called by the parser on SAX ProcessingInstruction events.

Reimplemented from SAXHandler.

virtual void NEDSAXHandler::startCdataSection (  )  [virtual]

Called by the parser on SAX CDataStart events.

Reimplemented from SAXHandler.

virtual void NEDSAXHandler::startElement ( const char *  name,
const char **  atts 
) [virtual]

Called by the parser on SAX StartElement events.

Reimplemented from SAXHandler.


The documentation for this class was generated from the following file:
Generated on Tue Dec 2 11:16:31 2014 for OMNeT++ NEDXML by  doxygen 1.6.3