#include <parse.h>
Public Methods | |
Parser (Buffer &buf) | |
Parser (Buffer &buf, const Symbols &st) | |
~Parser () | |
std::string | run () |
Parse template into a string. More... | |
bool | run (std::ostream &os) |
Parse template directly to stream. More... | |
bool | syntax () |
Just do a syntax check on template. More... | |
unsigned | geterrorcount () const |
Get the error count from a parse. More... | |
bool | geterrorlist (ErrorList &errlist) |
Get the error list from a parse. More... | |
bool | addfunction (const char *name, bool(*func)(std::ostream &, Object &)) |
Add a callback function. More... |
tptexception |
|
Construct a Parser for a Buffer.
|
|
Construct a Parser for a Buffer and Symbols table.
|
|
Destruct this Parser.
|
|
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.
|
|
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.
|