#include <xml/utf8/Builder.h>
Public Methods | |
| Position (const BufHandle &bufhdl, const size_t &bufoffset) | |
| Convenience initializing contructor. | |
| Position () | |
| Give things reasonable default values. | |
Public Attributes | |
| BufHandle | bufhdl_ |
| A buffer identifier passed into Lexer::lex. | |
| size_t | bufoffset_ |
| The offset from the beginning of the buffer represented by bufhdl_. | |
Since the Lexer works on character buffers, and a given token may extend across several buffers, it also needs a way to communicate which buffer a particular token started or ended in. To this end, since the Lexer reports the positions in the buffer of token beginnings and endings, it reports those positions using an identifier (i.e. handle) for which buffer the position was in, what the offset is from that buffer.
An offset may point one past the last achracter in the buffer identified by the handle.
This whole system is designed with three goals:
Definition at line 73 of file Builder.h.
1.3-rc1