Rudiments
|
#include <sax.h>
Inherits object.
Inherited by csvsax, inisax, jsonsax, propsax, and xmlsax.
Public Member Functions | |
sax () | |
virtual | ~sax () |
void | setIgnoreHeaderLines (uint64_t lines) |
uint64_t | getIgnoreHeaderLines () |
void | setIgnoreFooterLines (uint64_t lines) |
uint64_t | getIgnoreFooterLines () |
virtual bool | parse (input *in) |
virtual bool | parseFile (const char *filename) |
virtual bool | parseString (const char *string) |
const char * | getError () |
![]() | |
virtual | ~object () |
The sax class is a base class for a SAX-style parser. To use this class, you should create a class that inherits from one if its immediate children and implements the protected virtual methods of that class.
sax::sax | ( | ) |
Creates an instance of the sax class.
|
virtual |
Deletes this instance of the sax class.
If parseFile() or parseString() fails, this method returns the error that caused the failure.
uint64_t sax::getIgnoreFooterLines | ( | ) |
Returns the value set by setIgnoreFooter() or 0 if none was set.
uint64_t sax::getIgnoreHeaderLines | ( | ) |
Returns the value set by setIgnoreHeader() or 0 if none was set.
Configures the instance to ignore the last "lines" lines of the data.
Configures the instance to ignore the first "lines" lines and begin parsing after them.
If used in conjunction with setIgnoreHeaderUntil() then the lines specified here are ignored first, then lines are skipped until one begins with the pattern specified by setIgnoreHeaderUntil().