IWORKDiscardContext.h
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /*
3  * This file is part of the libetonyek project.
4  *
5  * This Source Code Form is subject to the terms of the Mozilla Public
6  * License, v. 2.0. If a copy of the MPL was not distributed with this
7  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8  */
9 
10 #ifndef IWORKDISCARDCONTEXT_H_INCLUDED
11 #define IWORKDISCARDCONTEXT_H_INCLUDED
12 
13 #include <boost/enable_shared_from_this.hpp>
14 #include <boost/shared_ptr.hpp>
15 
16 #include "IWORKXMLContext.h"
17 
18 namespace libetonyek
19 {
20 
21 class IWORKXMLParserState;
22 
23 class IWORKDiscardContext : public IWORKXMLContext, public boost::enable_shared_from_this<IWORKDiscardContext>
24 {
25  struct Data;
26 
27 public:
29 
30 protected:
31  virtual void startOfElement();
32  virtual void attribute(int name, const char *value);
33  virtual IWORKXMLContextPtr_t element(int name);
34  virtual void text(const char *value);
35  virtual void endOfElement();
36 
37 private:
39  unsigned m_level;
41  boost::shared_ptr<Data> m_data;
42 };
43 
44 }
45 
46 #endif // IWORKDISCARDCONTEXT_H_INCLUDED
47 
48 /* vim:set shiftwidth=2 softtabstop=2 expandtab: */
Definition: IWORKBezierElement.cpp:18
virtual void text(const char *value)
Process textual content of an element.
Definition: IWORKDiscardContext.cpp:112
virtual IWORKXMLContextPtr_t element(int name)
Create a context for parsing a child element.
Definition: IWORKDiscardContext.cpp:68
Definition: IWORKXMLContext.h:22
bool m_enableCollector
Definition: IWORKDiscardContext.h:40
boost::shared_ptr< IWORKXMLContext > IWORKXMLContextPtr_t
Definition: IWORKXMLContext.h:18
boost::shared_ptr< Data > m_data
Definition: IWORKDiscardContext.h:41
virtual void endOfElement()
Signalize the end of an element.
Definition: IWORKDiscardContext.cpp:116
unsigned m_level
Definition: IWORKDiscardContext.h:39
virtual void attribute(int name, const char *value)
Process an attribute.
Definition: IWORKDiscardContext.cpp:64
const char * name
Definition: IWORKToken.cpp:43
Definition: IWORKXMLParserState.h:30
IWORKDiscardContext(IWORKXMLParserState &state)
Definition: IWORKDiscardContext.cpp:46
IWORKXMLParserState & m_state
Definition: IWORKDiscardContext.h:38
virtual void startOfElement()
Signalize the start of an element.
Definition: IWORKDiscardContext.cpp:54
Definition: IWORKDiscardContext.h:23
Definition: IWORKDiscardContext.cpp:34

Generated for libetonyek by doxygen 1.8.8