DynGenPar
Dynamic Generalized Parser
Public Member Functions | Public Attributes | Protected Member Functions | List of all members
DynGenPar::ListTokenSource Class Reference
Inheritance diagram for DynGenPar::ListTokenSource:
Inheritance graph

Public Member Functions

 ListTokenSource ()
 
virtual ~ListTokenSource ()
 
virtual bool rewindTo (int pos, const LexerState &=LexerState())
 overridden because lists can be rewound More...
 
- Public Member Functions inherited from DynGenPar::TokenSource
 TokenSource ()
 
virtual ~TokenSource ()
 
Cat nextToken ()
 get the next token from the input, increment current position, save parse tree More...
 
Node parseTree ()
 get the parse tree for the last shifted token More...
 
virtual bool matchParseTree (const Node &treeToMatch)
 match the parse tree for the last shifted token against the given tree More...
 
int currentPosition ()
 get the current input position More...
 
virtual LexerState saveState ()
 saves the current lexer state, by default a null LexerState More...
 

Public Attributes

QList< CatinputTokens
 

Protected Member Functions

virtual Cat readToken ()
 just fetch the next token from the list More...
 
- Protected Member Functions inherited from DynGenPar::TokenSource
bool simpleRewind (int pos, bool rewindOnly=false)
 basic implementation of rewindTo for subclasses which support it More...
 

Additional Inherited Members

- Protected Attributes inherited from DynGenPar::TokenSource
int currPos
 
Node tree
 sub-parse-tree for hierarchical parsing More...
 

Detailed Description

Definition at line 883 of file dyngenpar.h.

Constructor & Destructor Documentation

◆ ListTokenSource()

DynGenPar::ListTokenSource::ListTokenSource ( )
inline

Definition at line 885 of file dyngenpar.h.

◆ ~ListTokenSource()

virtual DynGenPar::ListTokenSource::~ListTokenSource ( )
inlinevirtual

Definition at line 886 of file dyngenpar.h.

Member Function Documentation

◆ readToken()

virtual Cat DynGenPar::ListTokenSource::readToken ( )
inlineprotectedvirtual

just fetch the next token from the list

Implements DynGenPar::TokenSource.

Definition at line 894 of file dyngenpar.h.

◆ rewindTo()

virtual bool DynGenPar::ListTokenSource::rewindTo ( int  pos,
const LexerState = LexerState() 
)
inlinevirtual

overridden because lists can be rewound

Reimplemented from DynGenPar::TokenSource.

Definition at line 889 of file dyngenpar.h.

Member Data Documentation

◆ inputTokens

QList<Cat> DynGenPar::ListTokenSource::inputTokens

Definition at line 887 of file dyngenpar.h.


The documentation for this class was generated from the following file: