1
#ifndef SEEN_SIMPLE_SAX_H
2
#define SEEN_SIMPLE_SAX_H
8
* Jon A. Cruz <jon@joncruz.org>
10
* Copyright (C) 2004 AUTHORS
12
* Released under GNU GPL, read the file 'COPYING' for more information
15
#include <libxml/parser.h>
16
#include <glibmm/ustring.h>
26
virtual ~SaxHandler();
28
int parseMemory( const char* buffer, int size );
29
int parseFile( const char* filename );
31
static const char* errToStr( int errVal );
34
virtual void _startDocument() {}
35
virtual void _endDocument() {}
36
virtual void _startElement(const xmlChar */*name*/, const xmlChar **/*attrs*/) {}
37
virtual void _endElement(const xmlChar */*name*/) {}
38
virtual void _characters(const xmlChar */*ch*/, int /*len*/) {}
41
static void startDocument(void *user_data);
42
static void endDocument(void *user_data);
43
static void startElement(void *user_data,
45
const xmlChar **attrs);
46
static void endElement(void *user_data,
48
static void characters(void * user_data,
53
SaxHandler(SaxHandler const &);
54
SaxHandler &operator=(SaxHandler const &);
61
class FlatSaxHandler : public SaxHandler
65
virtual ~FlatSaxHandler();
68
virtual void _startElement(const xmlChar *name, const xmlChar **attrs);
69
virtual void _endElement(const xmlChar *name);
70
virtual void _characters(const xmlChar *ch, int len);
76
FlatSaxHandler(FlatSaxHandler const &);
77
FlatSaxHandler &operator=(FlatSaxHandler const &);
83
} // namespace Inkscape
89
c-file-style:"stroustrup"
90
c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
95
// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :
97
#endif // SEEN_SIMPLE_SAX_H