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

IReNodeBuilder Class Reference

#include <ire_node_builder.hh>

Inheritance diagram for IReNodeBuilder:

Inheritance graph
[legend]
List of all members.

Public Methods

virtual ReNodecreateOrNode (ReNode *pre, ReNode *post, const Position &pos)=0
virtual ReNodecreateCatNode (ReNode *pre, ReNode *post, const Position &pos)=0
virtual ReNodecreatePlusNode (ReNode *in, const Position &pos)=0
virtual ReNodecreateOptionalNode (ReNode *in, const Position &pos)=0
virtual ReNodecreateStarNode (ReNode *in, const Position &pos)=0
virtual ReNodecreateStringLiteralNode (const string &s, const Position &pos)=0
virtual ReNodecreateCharListNode (bool negated, const vector< CharClassDescriptor > &chars, const Position &pos)=0

Detailed Description

This is the regexp node builder's interface. The classes that build parse tree nodes for regular expressions found in the lexical section must implement this interface in order to be able to be notified by the parser when a regualr expressino was recognized in he input grammar.

All the methods receive, besides arguments specific to the node's kind, an object of type Position that indicates the position inside the input file where the expression has been identified.

Definition at line 95 of file ire_node_builder.hh.


Member Function Documentation

ReNode * IReNodeBuilder::createOrNode ( ReNode * pre,
ReNode * post,
const Position & pos ) [pure virtual]
 

Creates a new "|" node with children pre and post.

Reimplemented in DfaReNodeBuilder.

Referenced by IReNodeBuilder_createOrNode().

ReNode * IReNodeBuilder::createCatNode ( ReNode * pre,
ReNode * post,
const Position & pos ) [pure virtual]
 

Creates a new concatenation node with children pre and post.

Reimplemented in DfaReNodeBuilder.

Referenced by IReNodeBuilder_createCatNode().

ReNode * IReNodeBuilder::createPlusNode ( ReNode * in,
const Position & pos ) [pure virtual]
 

Creates a new "+" node whose operand is in.

Reimplemented in DfaReNodeBuilder.

Referenced by IReNodeBuilder_createPlusNode().

ReNode * IReNodeBuilder::createOptionalNode ( ReNode * in,
const Position & pos ) [pure virtual]
 

Creates a new "?" node whose operand in.

Reimplemented in DfaReNodeBuilder.

Referenced by IReNodeBuilder_createOptionalNode().

ReNode * IReNodeBuilder::createStarNode ( ReNode * in,
const Position & pos ) [pure virtual]
 

Creates a "*" node whose operand is in.

Reimplemented in DfaReNodeBuilder.

Referenced by IReNodeBuilder_createStarNode().

ReNode * IReNodeBuilder::createStringLiteralNode ( const string & s,
const Position & pos ) [pure virtual]
 

Creates a node that matches the gicen string literal s.

Reimplemented in DfaReNodeBuilder.

Referenced by IReNodeBuilder_createStringLiteralNode().

ReNode * IReNodeBuilder::createCharListNode ( bool negated,
const vector< CharClassDescriptor > & chars,
const Position & pos ) [pure virtual]
 

Creates a new node that matches the characters classes given in \s chars or, if negated is true, the characters that do not belong to the classes in chars.

Reimplemented in DfaReNodeBuilder.

Referenced by IReNodeBuilder_createCharListNode().


The documentation for this class was generated from the following file:
Generated at Tue Jul 9 21:07:11 2002 for CppCC by doxygen1.2.8.1 written by Dimitri van Heesch, © 1997-2001