Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
libebook::PDBParser Class Reference

`#include <PDBParser.h>`

Inheritance diagram for libebook::PDBParser:

## Public Member Functions
| PDBParser (librevenge::RVNGInputStream *input, librevenge::RVNGTextInterface *document=0)
virtual | ~PDBParser ()
Public Member Functions inherited from libebook::PDXParser
virtual | ~PDXParser ()=0
bool | parse ()
| Parse input and produce output to document. More...

## Static Public Member Functions
static bool | checkType (unsigned type, unsigned creator)

## Private Member Functions
| PDBParser (const PDBParser &)
PDBParser & | operator= (const PDBParser &)
virtual void | readAppInfoRecord (librevenge::RVNGInputStream *record)
virtual void | readSortInfoRecord (librevenge::RVNGInputStream *record)
virtual void | readIndexRecord (librevenge::RVNGInputStream *record)
virtual void | readDataRecord (librevenge::RVNGInputStream *record, bool last)
void | createConverter (const std::vector< char > &text)
void | openDocument ()
void | closeDocument ()
void | handleText (const std::vector< char > &text)
void | openParagraph ()
void | closeParagraph (bool continuing=false)
void | handleCharacters (const char *text)

## Private Attributes
bool | m_compressed
unsigned | m_textLength
unsigned | m_recordCount
unsigned | m_recordSize
unsigned | m_read
bool | m_openedParagraph
| Signalize that a paragraph is split at record break. More...
bool | m_openedDocument
EBOOKCharsetConverter * | m_converter

## Additional Inherited Members
Protected Member Functions inherited from libebook::PDXParser
| PDXParser (librevenge::RVNGInputStream *input, librevenge::RVNGTextInterface *document, unsigned type, unsigned creator)
| Instantiate a parser for a document in Palm Database Format. More...
librevenge::RVNGTextInterface * | getDocument () const
| Get the document generator used for this parsing run. More...
const char * | getName () const
librevenge::RVNGInputStream * | getAppInfoRecord () const
| Return a stream for the format's appInfo record, if it is present. More...
librevenge::RVNGInputStream * | getIndexRecord () const
| Return a stream for the format's index record. More...
unsigned | getDataRecordCount () const
| Return the number of data records in the document. More...
librevenge::RVNGInputStream * | getDataRecord (unsigned n) const
| Return a stream for the n-th data record. More...
librevenge::RVNGInputStream * | getDataRecords () const
| Return a stream for all data records. More...
librevenge::RVNGInputStream * | getDataRecords (unsigned first, unsigned last) const
| Return a stream for data records in a given range. More...

## Constructor & Destructor Documentation

## § PDBParser() [1/2]

libebook::PDBParser::PDBParser | ( | const PDBParser & |  | ) |
| private

## § PDBParser() [2/2]

libebook::PDBParser::PDBParser | ( | librevenge::RVNGInputStream * | input,
|  | librevenge::RVNGTextInterface * | document = `0`
| ) |  |
| explicit

## § ~PDBParser()

libebook::PDBParser::~PDBParser | ( |  | ) |
| virtual

## Member Function Documentation

## § checkType()

bool libebook::PDBParser::checkType | ( | unsigned | type,
|  | unsigned | creator
| ) |  |
| static

## § closeDocument()

void libebook::PDBParser::closeDocument | ( |  | ) |
| private

Referenced by readDataRecord().

## § closeParagraph()

void libebook::PDBParser::closeParagraph | ( | bool | continuing = `false` | ) |
| private

Referenced by closeDocument(), and handleText().

## § createConverter()

void libebook::PDBParser::createConverter | ( | const std::vector< char > & | text | ) |
| private

Referenced by readDataRecord().

## § handleCharacters()

void libebook::PDBParser::handleCharacters | ( | const char * | text | ) |
| private

Referenced by handleText().

## § handleText()

void libebook::PDBParser::handleText | ( | const std::vector< char > & | text | ) |
| private

Referenced by readDataRecord().

## § openDocument()

void libebook::PDBParser::openDocument | ( |  | ) |
| private

Referenced by readDataRecord().

## § openParagraph()

void libebook::PDBParser::openParagraph | ( |  | ) |
| private

Referenced by handleText().

## § operator=()

PDBParser& libebook::PDBParser::operator= | ( | const PDBParser & |  | ) |
| private

## § readAppInfoRecord()

void libebook::PDBParser::readAppInfoRecord | ( | librevenge::RVNGInputStream * | record | ) |
| private virtual

Implements libebook::PDXParser.

## § readDataRecord()

void libebook::PDBParser::readDataRecord | ( | librevenge::RVNGInputStream * | record,
|  | bool | last
| ) |  |
| private virtual

Implements libebook::PDXParser.

## § readIndexRecord()

void libebook::PDBParser::readIndexRecord | ( | librevenge::RVNGInputStream * | record | ) |
| private virtual

Implements libebook::PDXParser.

## § readSortInfoRecord()

void libebook::PDBParser::readSortInfoRecord | ( | librevenge::RVNGInputStream * | record | ) |
| private virtual

Implements libebook::PDXParser.

## Member Data Documentation

## § m_compressed

bool libebook::PDBParser::m_compressed
| private

Referenced by readDataRecord(), and readIndexRecord().

## § m_converter

EBOOKCharsetConverter* libebook::PDBParser::m_converter
| private

Referenced by createConverter(), handleText(), openDocument(), and ~PDBParser().

## § m_openedDocument

bool libebook::PDBParser::m_openedDocument
| private

Referenced by closeDocument(), openDocument(), and readDataRecord().

## § m_openedParagraph

bool libebook::PDBParser::m_openedParagraph
| private

Signalize that a paragraph is split at record break.

We do not want to open a new paragraph in this case.

NOTE: I do not know if this is actually done. It is quite possible that a record always ends at a paragraph break. But AFAICS there is no prescribed special handling for '
', so this is at least possible.

Referenced by closeDocument(), closeParagraph(), and openParagraph().

## § m_read

unsigned libebook::PDBParser::m_read
| private

Referenced by readDataRecord().

## § m_recordCount

unsigned libebook::PDBParser::m_recordCount
| private

Referenced by readIndexRecord().

## § m_recordSize

unsigned libebook::PDBParser::m_recordSize
| private

Referenced by readDataRecord(), and readIndexRecord().

## § m_textLength

unsigned libebook::PDBParser::m_textLength
| private

Referenced by readIndexRecord().

The documentation for this class was generated from the following files:

- PDBParser.h
- PDBParser.cpp