oopapidocs
2.0
|
A class designed for traversing and transforming Docbook Documents. More...
#include <docbookwalker.h>
Public Member Functions | |
virtual QDomDocument | transform () |
Traverses whole tree. | |
virtual int | visited () const |
Protected Member Functions | |
virtual bool | visit (int depth, Element e) |
Visits the current Element. | |
QString | currentHeading () const |
QString | heading (Element sect) const |
A class designed for traversing and transforming Docbook Documents.
Keeps track of section::s and chapter::s.
Definition at line 12 of file docbookwalker.h.
QString DocbookWalker::currentHeading | ( | ) | const [protected] |
Definition at line 43 of file docbookwalker.cpp.
References heading().
QString DocbookWalker::heading | ( | Element | sect | ) | const [protected] |
sect | a chapter, section or appendix |
Definition at line 18 of file docbookwalker.cpp.
References DocbookDoc::getTitle().
Referenced by currentHeading().
QDomDocument DocbookWalker::transform | ( | ) | [virtual] |
Traverses whole tree.
Definition at line 101 of file docbookwalker.cpp.
bool DocbookWalker::visit | ( | int | depth, |
Element | e | ||
) | [protected, virtual] |
Visits the current Element.
Handles elements like <chapter> <section> nd <appendix> for numbering purposes.
Called from walkTree from transform. Not to be called pubclicly.
You can override this, handle specific elements, and call the base class version for elements you do not handle.
e | the Element to visit |
depth | the current depth of the tree |
Definition at line 63 of file docbookwalker.cpp.
virtual int DocbookWalker::visited | ( | ) | const [inline, virtual] |
Definition at line 21 of file docbookwalker.h.