Ancestry.QueryProcessor.Parse.Lexer.this C# (CSharp) Method

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
        public LexerToken this[int index, bool checkActive]
        {
            get
            {
                System.Diagnostics.Debug.Assert(index < LookAheadCount, "Lexer look ahead attempt exceeds maximum");
                LexerToken token = _tokens[(_currentIndex + index) % LookAheadCount];
                if (checkActive && (token.Type == TokenType.Unknown))
                    throw new LexerException(LexerException.Codes.NoActiveToken);
                return token;
            }
        }

Same methods

Lexer::this ( int index ) : LexerToken