In This Article

LexicalScopeTokenData Class

Provides IToken lexer data based on a token ID and an ILexicalScope.

public class LexicalScopeTokenData : IMergableTokenLexerData
Inheritance:
object object
Implements:
IMergableTokenLexerData

Constructors

LexicalScopeTokenData(ILexicalScope, int)

Initializes a new instance of the LexicalScopeTokenData class.

public LexicalScopeTokenData(ILexicalScope lexicalScope, int tokenId)
Parameter Type Description
lexicalScope ILexicalScope

The ILexicalScope that contains the token.

tokenId int

The ID of the token.

Properties

ClassificationType

Gets the IClassificationType assigned to the token.

public IClassificationType ClassificationType { get; }

Property Value

IClassificationType:

The IClassificationType assigned to the token.

Lexer

Gets the IMergableLexer that contains the token.

public IMergableLexer Lexer { get; }

Property Value

IMergableLexer:

The IMergableLexer that contains the token.

LexicalScope

Gets the ILexicalScope, if any, that defines the token.

public ILexicalScope LexicalScope { get; }

Property Value

ILexicalScope:

The ILexicalScope, if any, that defines the token.

Remarks

If this value is null, the token was not defined by a lexical scope.

LexicalState

Gets the ILexicalState that contains the token.

public ILexicalState LexicalState { get; }

Property Value

ILexicalState:

The ILexicalState that contains the token.

TokenId

Gets the token ID assigned to the token.

public int TokenId { get; }

Property Value

int:

The token ID assigned to the token.

TokenKey

Gets the token key assigned to the token, if it is known.

public virtual string TokenKey { get; }

Property Value

string:

The token key assigned to the token, if it is known.

Methods

Equals(object)

Determines whether the specified Object is equal to the current Object.

public override bool Equals(object obj)
Parameter Type Description
obj object

The Object to compare to the current Object.

Returns

bool:

true if the specified Object is equal to the current Object; otherwise, false.

GetHashCode()

Returns a hash code for this object.

public override int GetHashCode()

Returns

int:

An integer value that specifies a hash value for this object.

Inherited Members