Public Member Functions | |
IParser (const char *filename, Symbols &st) | |
IParser (const char *buf, unsigned long size, Symbols &st) | |
IParser (Buffer &buf, Symbols &st) | |
~IParser () | |
std::string | run () |
Parse template into a string. | |
bool | run (std::ostream &os) |
Parse template directly to stream. | |
bool | syntax () |
Just do a syntax check on template. | |
unsigned | geterrorcount () const |
Get the error count from a parse. | |
bool | geterrorlist (ErrorList &errlist) |
Get the error list from a parse. | |
void | addincludepath (const char *path) |
Add an include search path. | |
bool | addfunction (const char *name, bool(*func)(std::ostream &, Object &)) |
Add a callback function. |
tptexception |
|
Construct a IParser for the specified file and Symbols table.
|
|
Construct a IParser for the specified fixed length buffer and Symbols table.
|
|
Construct a IParser for a Buffer and Symbols table.
|
|
Destruct this IParser. |
|
Add a callback function. Register a callback function to handle TPT calls to the specified function name. See the LibTPT Documentation for details on how to write a a callback funcion.
|
|
Add an include search path. Add a path to the Include search list. By default, only ./ is searched.
|
|
Get the error count from a parse. Get the number of errors and warnings.
|
|
Get the error list from a parse. Copy the errors and warnings generated by the last parse into the specified array.
|
|
Parse template directly to stream. Parse the template in Buffer, outputing the result to the given stream while parsing.
|
|
Parse template into a string. Parse the template in Buffer and return the result as a string. Note: This method is provided for completeness, but the preferred method of parsing is to use streams instead. |
|
Just do a syntax check on template. Perform only syntax checking on Buffer.
|