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

TypechainLexer Class Reference

This class is a yyFlexLexer subclass with two pure virtual methods you can override to process identifiers and final types:. More...

#include <tclexer.hh>

Inheritance diagram for TypechainLexer:

yyFlexLexer FlexLexer FlexLexer List of all members.

Public Member Functions

Protected Member Functions

Protected Attributes


Detailed Description

This class is a yyFlexLexer subclass with two pure virtual methods you can override to process identifiers and final types:.

void complete_token(string token, map<string,string> params);

This method is called whenever a complete identifier token has been parsed, with parameters (which will have no contents if there were no parameters. If a key was supplied with no value, the key will be present with an empty string for value. If an empty identifier was given (e.g. "foo;;bar;baz") then this method will be called with an empty string for token (you may then issue an error, warning, or simply ignore it, as you wish). Reserved identifiers (such as "type") are also passed to this method.

void final_type(string token, map<string,string> params);

This method is called once for the final media type identifer token has been parsed, with parameters, analagous to complete_token.

Definition at line 66 of file tclexer.hh.


Constructor & Destructor Documentation

TypechainLexer::TypechainLexer const string &  typestr  )  [inline]
 

Constructor.

Parameters:
typestring The type string.

Definition at line 86 of file tclexer.hh.


Member Function Documentation

void TypechainLexer::clear_vars  )  [inline, protected]
 

Definition at line 74 of file tclexer.hh.

virtual void TypechainLexer::complete_token string  token,
map< string, string >  params
[pure virtual]
 

Override this in your subclass to take action on a token.

virtual void TypechainLexer::final_type string  token,
map< string, string >  params
[pure virtual]
 

Override this in your subclass to take action on the final type token.

int TypechainLexer::yylex  )  [virtual]
 

Call this to do the scan.

Reimplemented from yyFlexLexer.


Member Data Documentation

char* TypechainLexer::lastkey [protected]
 

Definition at line 71 of file tclexer.hh.

Referenced by clear_vars(), and TypechainLexer().

map<string, string> TypechainLexer::params [protected]
 

Definition at line 70 of file tclexer.hh.

Referenced by clear_vars().

string TypechainLexer::token [protected]
 

Definition at line 69 of file tclexer.hh.

Referenced by clear_vars().

string TypechainLexer::typestring [protected]
 

Definition at line 72 of file tclexer.hh.

Referenced by TypechainLexer().


The documentation for this class was generated from the following file:
Generated on Tue Aug 12 03:55:58 2003 for Interreality Project - VOS by doxygen 1.3.2