ZTXTParser.h Source File documentation

ZTXTParser.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 libe-book 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 ZTXTPARSER_H_INCLUDED
11#define ZTXTPARSER_H_INCLUDED
12
13#include "PDBParser.h"
14
15
16namespace libebook
17{
18
19 class ZTXTParser : public PDBParser
20{
21public:
22 explicit ZTXTParser(librevenge::RVNGInputStream *input, librevenge::RVNGTextInterface *document = nullptr);
23
24 static bool checkType(unsigned type, unsigned creator);
25
26 void readAppInfoRecord(librevenge::RVNGInputStream *record) override;
27 void readSortInfoRecord(librevenge::RVNGInputStream *record) override;
28 void readIndexRecord(librevenge::RVNGInputStream *record) override;
29 void readDataRecord(librevenge::RVNGInputStream *record, bool = true) override;
30
31 void readDataRecords() override;
32
33private:
34 void openDocument();
35 void closeDocument();
36 void handleText(const librevenge::RVNGString &text);
37
38private:
39 unsigned m_recordCount;
40 unsigned m_size;
41 unsigned m_recordSize;
42};
43
44} // namespace libebook
45
46#endif // ZTXTPARSER_H_INCLUDED
47/* vim:set shiftwidth=2 softtabstop=2 expandtab: */
PDBParser.h
libebook::PDBParser::PDBParser
PDBParser(const PDBParser &other)
libebook::ZTXTParser::m_recordSize
unsigned m_recordSize
Definition ZTXTParser.h:41
libebook::ZTXTParser::ZTXTParser
ZTXTParser(librevenge::RVNGInputStream *input, librevenge::RVNGTextInterface *document=nullptr)
Definition ZTXTParser.cpp:25
libebook::ZTXTParser::closeDocument
void closeDocument()
Definition ZTXTParser.cpp:97
libebook::ZTXTParser::readDataRecords
void readDataRecords() override
Definition ZTXTParser.cpp:74
libebook::ZTXTParser::readAppInfoRecord
void readAppInfoRecord(librevenge::RVNGInputStream *record) override
Definition ZTXTParser.cpp:38
libebook::ZTXTParser::openDocument
void openDocument()
Definition ZTXTParser.cpp:86
libebook::ZTXTParser::readSortInfoRecord
void readSortInfoRecord(librevenge::RVNGInputStream *record) override
Definition ZTXTParser.cpp:42
libebook::ZTXTParser::m_size
unsigned m_size
Definition ZTXTParser.h:40
libebook::ZTXTParser::m_recordCount
unsigned m_recordCount
Definition ZTXTParser.h:39
libebook::ZTXTParser::checkType
static bool checkType(unsigned type, unsigned creator)
Definition ZTXTParser.cpp:33
libebook::ZTXTParser::readIndexRecord
void readIndexRecord(librevenge::RVNGInputStream *record) override
Definition ZTXTParser.cpp:46
libebook::ZTXTParser::readDataRecord
void readDataRecord(librevenge::RVNGInputStream *record, bool=true) override
Definition ZTXTParser.cpp:55
libebook::ZTXTParser::handleText
void handleText(const librevenge::RVNGString &text)
Definition ZTXTParser.cpp:103
libebook::EBOOKHTMLToken::type
@ type
Definition EBOOKHTMLToken.h:258
libebook::EBOOKHTMLToken::input
@ input
Definition EBOOKHTMLToken.h:89
libebook::EBOOKHTMLToken::text
@ text
Definition EBOOKHTMLToken.h:257
libebook::EBOOKOPFToken::creator
@ creator
Definition EBOOKOPFToken.h:50
libebook
Definition BBeBCollector.cpp:19