KEYParser.h Source File documentation

- Main Page
- Related Pages
- Namespaces
- Classes
- Files

- File List
- File Members

KEYParser.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 KEYPARSER_H_INCLUDED
11 #define KEYPARSER_H_INCLUDED
12
13 #include "libetonyek_utils.h"
14 #include "KEYXMLReader.h"
15
16 namespace libetonyek
17 {
18
19 class KEYCollector;
20 class KEYDefaults;
21
22 class KEYParser
23 {
24 // -Weffc++
25 KEYParser(const KEYParser &);
26 KEYParser &operator=(const KEYParser &);
27
28 public:
29 KEYParser(const RVNGInputStreamPtr_t &input, KEYCollector *collector, const KEYDefaults &defaults);
30 virtual ~KEYParser() = 0;
31 bool parse();
32
33 KEYCollector *getCollector() const;
34 const KEYDefaults &getDefaults() const;
35
36 private:
37 virtual void processXmlNode(const KEYXMLReader &reader) = 0;
38 virtual KEYXMLReader::TokenizerFunction_t getTokenizer() const = 0;
39
40 bool processXmlDocument(const KEYXMLReader &reader);
41
42 private:
43 RVNGInputStreamPtr_t m_input;
44 KEYCollector *m_collector;
45 const KEYDefaults &m_defaults;
46 };
47
48 } // namespace libetonyek
49
50 #endif // KEYPARSER_H_INCLUDED
51
52 /* vim:set shiftwidth=2 softtabstop=2 expandtab: */
libetonyek
Definition: EtonyekDocument.cpp:40
libetonyek::KEYParser::getCollector
KEYCollector * getCollector() const
Definition: KEYParser.cpp:35
libetonyek::KEYParser::~KEYParser
virtual ~KEYParser()=0
Definition: KEYParser.cpp:25
libetonyek::KEYParser::m_collector
KEYCollector * m_collector
Definition: KEYParser.h:44
libetonyek::KEYParser::getTokenizer
virtual KEYXMLReader::TokenizerFunction_t getTokenizer() const =0
libetonyek::KEYParser::operator=
KEYParser & operator=(const KEYParser &)
libetonyek::KEYParser::getDefaults
const KEYDefaults & getDefaults() const
Definition: KEYParser.cpp:40
libetonyek::KEYParser::processXmlDocument
bool processXmlDocument(const KEYXMLReader &reader)
Definition: KEYParser.cpp:45
libetonyek::KEYParser::KEYParser
KEYParser(const KEYParser &)
libetonyek::KEYParser::processXmlNode
virtual void processXmlNode(const KEYXMLReader &reader)=0
libetonyek::KEYParser::parse
bool parse()
Definition: KEYParser.cpp:29
libetonyek::KEYParser
Definition: KEYParser.h:22
libetonyek::KEYXMLReader
Definition: KEYXMLReader.h:20
libetonyek::RVNGInputStreamPtr_t
boost::shared_ptr< librevenge::RVNGInputStream > RVNGInputStreamPtr_t
Definition: libetonyek_utils.h:88
libetonyek::KEYParser::m_defaults
const KEYDefaults & m_defaults
Definition: KEYParser.h:45
libetonyek::KEYCollector
Definition: KEYCollector.h:29
input
RVNGInputStreamPtr_t input
Definition: EtonyekDocument.cpp:59
libetonyek_utils.h
libetonyek::KEYDefaults
A representation of default values for various parts of the format.
Definition: KEYDefaults.h:30
KEYXMLReader.h
libetonyek::KEYXMLReader::TokenizerFunction_t
boost::function< int(const char *)> TokenizerFunction_t
Definition: KEYXMLReader.h:126
libetonyek::KEYParser::m_input
RVNGInputStreamPtr_t m_input
Definition: KEYParser.h:43