C# Class Ancestry.QueryProcessor.Parse.Lexer

Mostrar archivo Open project: Ancestry/DotQL Class Usage Examples

Public Methods

Method Description
Lexer ( string input ) : System It is an error to access the current TokenType until NextToken has been called.
NextToken ( ) : LexerToken

Advances the current token.

PeekToken ( int count ) : LexerToken

Gets the symbol the specified number of tokens ahead without advancing the current token.

If the token is not a symbol, returns an empty string.

PeekTokenSymbol ( int count ) : string

Gets the symbol the specified number of tokens ahead without advancing the current token.

If the token is not a symbol, returns an empty string.

this ( int index ) : LexerToken
this ( int index, bool checkActive ) : LexerToken

The token a specific number of tokens ahead of the current token.

Private Methods

Method Description
ReadNext ( int index ) : bool

Reads the next token into the specified location within the buffer.

Method Details

Lexer() public method

It is an error to access the current TokenType until NextToken has been called.
public Lexer ( string input ) : System
input string
return System

NextToken() public method

Advances the current token.
public NextToken ( ) : LexerToken
return LexerToken

PeekToken() public method

Gets the symbol the specified number of tokens ahead without advancing the current token.
If the token is not a symbol, returns an empty string.
public PeekToken ( int count ) : LexerToken
count int
return LexerToken

PeekTokenSymbol() public method

Gets the symbol the specified number of tokens ahead without advancing the current token.
If the token is not a symbol, returns an empty string.
public PeekTokenSymbol ( int count ) : string
count int
return string

this() public method

public this ( int index ) : LexerToken
index int
return LexerToken

this() public method

The token a specific number of tokens ahead of the current token.
public this ( int index, bool checkActive ) : LexerToken
index int
checkActive bool
return LexerToken