Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

CharBuffer Class Reference

#include <CharBuffer.hpp>

Inheritance diagram for CharBuffer:

InputBuffer List of all members.

Public Methods

 CharBuffer (ANTLR_USE_NAMESPACE(std) istream &input_)
 Create a character buffer.

int getChar ()
 Get the next character from the stream.


Detailed Description

A Stream of characters fed to the lexer from a InputStream that can be rewound via mark()/rewind() methods.

A dynamic array is used to buffer up all the input characters. Normally, "k" characters are stored in the buffer. More characters may be stored during guess mode (testing syntactic predicate), or when LT(i>k) is referenced. Consumption of characters is deferred. In other words, reading the next character is not done by consume(), but deferred until needed by LA or LT.

See also:
antlr.CharQueue


Constructor & Destructor Documentation

CharBuffer::CharBuffer ANTLR_USE_NAMESPACE(std) istream &    input_
 

Create a character buffer.

Create a character buffer. Enable fail and bad exceptions, if supported by platform.


Member Function Documentation

int CharBuffer::getChar void    [virtual]
 

Get the next character from the stream.

Get the next character from the stream. May throw CharStreamIOException when something bad happens (not EOF) (if supported by platform).

Implements InputBuffer.


The documentation for this class was generated from the following files:
Generated on Wed Nov 3 12:59:25 2004 for Lemur Toolkit by doxygen1.2.18