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

vcsn::algebra::Lexer Struct Template Reference
[Series]

Lexer class for the rational expression parser. More...

List of all members.

Public Methods

void lex_error (const std::string &msg="Lex error.")
 Put the lexer into an error state.

void lex (const std::string &in, const Element< S, T > &e)
 Perform lexing. More...

bool error () const
 Return true when an error occured.

const std::string & error_msg () const
 Return the error message.

krat_exp_token_t first () const
 Return the first token.

krat_exp_token_t second () const
 Return the second token.

void eat ()
 Shift tokens. More...


Detailed Description

template<class S, class T>
struct vcsn::algebra::Lexer< S, T >

Lexer class for the rational expression parser.


Member Function Documentation

void lex const std::string &    in,
const Element< S, T > &    e
[inline]
 

Perform lexing.

Parameters:
in  The rational expression to lex, as a string.
e  The element which will be used later for parsing. It used to guess words and weights types.

void eat   [inline]
 

Shift tokens.

Remove the first token from the token stream. So second becames first, third becames second, and so on...


Generated on Wed Jul 2 19:09:13 2003 for Vaucanson by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002