Inherits YGP::ParseToText.
Public Member Functions | |
CBParseToText (const char *value, const char *description, PARSECALLBACK callback, unsigned int max=1, unsigned int min=1, bool skipWhitespace=true) | |
CBParseToText (const CBParseToText &other) | |
CBParseToText & | operator= (const CBParseToText &other) |
void | setCallback (PARSECALLBACK callback) |
Protected Member Functions | |
virtual int | found (const char *pFoundValue, unsigned int len) |
Parsing of this element is stopped, after the specified text is found (or the maximal cardinality is reached).
If this text has been found, the callback is called with the name of the scanned text passed als first parameter and the number of found entries as second.
See ParseObject for a general description of the parser and ParseToText for a description of how this class parses its object.
YGP::CBParseToText::CBParseToText | ( | const char * | value, | |
const char * | description, | |||
PARSECALLBACK | callback, | |||
unsigned int | max = 1 , |
|||
unsigned int | min = 1 , |
|||
bool | skipWhitespace = true | |||
) | [inline] |
Constructor setting explicit the length ot the data to parse; with callback to call if object is found.
YGP::CBParseToText::CBParseToText | ( | const CBParseToText & | other | ) | [inline] |
Sets the callback to the passed value.
virtual int YGP::CBParseToText::found | ( | const char * | pFoundValue, | |
unsigned int | ||||
) | [protected, virtual] |
Callback if an object was found.
Pointer | to found value | |
Length | of found value |
Reimplemented from YGP::ParseObject.
void YGP::CBParseToText::setCallback | ( | PARSECALLBACK | callback | ) | [inline] |
Sets the callback to the passed value.