#include <iscanner_spec.hh>
Inheritance diagram for IScannerSpec:
Public Methods | |
virtual | ~IScannerSpec () |
virtual IReNodeBuilder& | getReNodeBuilder ()=0 |
virtual void | addRegToken (const vector< string > &states, const string &name, ReNode *regexp, const string &tokenAction, const Position &pos)=0 throw (ParseException) |
virtual void | addSkipToken (const vector< string > &states, const string &name, ReNode *regexp, const string &tokenAction, const Position &pos)=0 throw (ParseException) |
virtual void | addMoreToken (const vector< string > &states, const string &name, ReNode *regexp, const string &tokenAction, const Position &pos)=0 throw (ParseException) |
virtual void | addKeywordToken (const vector< string > &states, const string &name, ReNode *regexp, const string &tokenAction, const Position &pos)=0 throw (ParseException) |
virtual void | addSpecialToken (const string &name, const Position &pos)=0 throw (ParseException) |
virtual void | setPreambleCode (const string &block, const Position &pos)=0 |
virtual void | addCodeBlock (const string &block, const Position &pos)=0 |
virtual void | setInheritance (const string &inheritance, const Position &pos)=0 |
virtual void | setClassName (const string &className)=0 |
virtual void | dump (ostream &os) const=0 |
All the methods that are called from the parser in order to add information to the parse treee receive the position inside the input file where the information was found.
Definition at line 70 of file iscanner_spec.hh.
|
Definition at line 74 of file iscanner_spec.hh. |
|
Returns a referece to the regexps node builder that should be used bu the parser to create the parse tree ndoes of the regular expressions of this scanner. Reimplemented in ScannerSpec. Referenced by LexYaccParser::parse().
|
|
Adds a new regular token declaratino to this scanner spec. states is the list of lexical states into which this token will be accepted. name is the name of the token regexp points to the root of the parse tree that describes the token's regexp. tokenAction contains the user code to be executed after a token of this type is matched
Reimplemented in ScannerSpec. Referenced by IScannerSpec_addRegToken().
|
|
Adds a new "skip" token declaratino to this scanner spec. states is the list of lexical states into which this token will be accepted. name is the name of the token regexp points to the root of the parse tree that describes the token's regexp. tokenAction contains the user code to be executed after a token of this type is matched
Reimplemented in ScannerSpec. Referenced by IScannerSpec_addSkipToken().
|
|
Adds a new "more" token declaratino to this scanner spec. states is the list of lexical states into which this token will be accepted. name is the name of the token regexp points to the root of the parse tree that describes the token's regexp. tokenAction contains the user code to be executed after a token of this type is matched
Reimplemented in ScannerSpec. Referenced by IScannerSpec_addMoreToken().
|
|
Adds a new "keyword" token declaratino to this scanner spec. states is the list of lexical states into which this token will be accepted. name is the name of the token regexp points to the root of the parse tree that describes the token's regexp. tokenAction contains the user code to be executed after a token of this type is matched
Reimplemented in ScannerSpec. Referenced by IScannerSpec_addKeywordToken().
|
|
Adds a new "special" token declaration to this scanner spec. name is the token's name.
Reimplemented in ScannerSpec. Referenced by IScannerSpec_addSpecialToken().
|
|
Sets the preamble code string for this scanner spwecification. The \s block string contains the block of code that precceded the lexical section without the enclosing brackets. Reimplemented in ScannerSpec. Referenced by IScannerSpec_setPreambleCode().
|
|
Adds a new block of user code to this scanner spec. The block string contains a block of userr code that was found inside the lexical section, without the enclosing brackets. Reimplemented in ScannerSpec. Referenced by IScannerSpec_addCodeBlock().
|
|
Sets the inheritance string for this scanner spec. The inheritance string contains the string that followed the ":" after the scanner's class name, up to the "{". Reimplemented in ScannerSpec. Referenced by IScannerSpec_setInheritance().
|
|
Sets the scanner slass name. Reimplemented in ScannerSpec. Referenced by IScannerSpec_setClassName().
|
|
If DEBUG is enabled, this method will dump all the data currently contained into this spec into the given stream Reimplemented in ScannerSpec. Referenced by LexYaccParser::parse().
|