ResidualVM logo ResidualVM website - Forums - Contact us BuildBot - Doxygen - Wiki curved edge

xmlparser.h File Reference

#include "common/scummsys.h"
#include "common/types.h"
#include "common/fs.h"
#include "common/list.h"
#include "common/hashmap.h"
#include "common/hash-str.h"
#include "common/stack.h"
#include "common/memorypool.h"
Include dependency graph for xmlparser.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  Common::XMLParser
 The base XMLParser class implements generic functionality for parsing XML-like files. More...
struct  Common::XMLParser::XMLKeyLayout
 nested struct representing the layout of the XML file More...
struct  Common::XMLParser::XMLKeyLayout::XMLKeyProperty
struct  Common::XMLParser::ParserNode
 Struct representing a parsed node. More...

Namespaces

namespace  Common
 

Internal interface to the QuickTime audio decoder.


Defines

#define MAX_XML_DEPTH   8
#define XML_KEY(keyName)
#define XML_KEY_RECURSIVE(keyName)
#define KEY_END()   layout.pop(); }
#define XML_PROP(propName, req)
#define CUSTOM_XML_PARSER(parserName)
#define PARSER_END()   layout.clear(); }

Define Documentation

#define CUSTOM_XML_PARSER (   parserName  ) 
Value:
protected: \
    typedef parserName kLocalParserName; \
    bool keyCallback(ParserNode *node) {return node->layout->doCallback(this, node); }\
    struct CustomXMLKeyLayout : public XMLKeyLayout {\
        typedef bool (parserName::*ParserCallback)(ParserNode *node);\
        ParserCallback callback;\
        bool doCallback(XMLParser *parent, ParserNode *node) {return ((kLocalParserName *)parent->*callback)(node);} };\
    virtual void buildLayout() { \
        Common::Stack<XMLKeyLayout *> layout; \
        CustomXMLKeyLayout *lay = 0; \
        XMLKeyLayout::XMLKeyProperty prop; \
        _XMLkeys = new CustomXMLKeyLayout; \
        layout.push(_XMLkeys);

Definition at line 64 of file xmlparser.h.

#define KEY_END (  )     layout.pop(); }

Definition at line 55 of file xmlparser.h.

#define MAX_XML_DEPTH   8

Definition at line 41 of file xmlparser.h.

#define PARSER_END (  )     layout.clear(); }

Definition at line 79 of file xmlparser.h.

#define XML_KEY (   keyName  ) 
Value:
{\
        lay = new CustomXMLKeyLayout;\
        lay->callback = (&kLocalParserName::parserCallback_##keyName);\
        layout.top()->children[#keyName] = lay;\
        layout.push(lay); \
        _layoutList.push_back(lay);

Definition at line 43 of file xmlparser.h.

#define XML_KEY_RECURSIVE (   keyName  ) 
Value:
{\
            layout.top()->children[#keyName] = layout.top();\
            layout.push(layout.top());\
        }

Definition at line 50 of file xmlparser.h.

#define XML_PROP (   propName,
  req 
)
Value:
{\
        prop.name = #propName; \
        prop.required = req; \
        layout.top()->properties.push_back(prop); }

Definition at line 57 of file xmlparser.h.



Generated on Sat Feb 16 2019 05:03:13 for ResidualVM by doxygen 1.7.1
curved edge   curved edge