In This Article

AstNodeIdProviderBase Class

Represents an abstract base class for an object that provides static IDs for the AST nodes of an ISyntaxLanguage.

public abstract class AstNodeIdProviderBase : IAstNodeIdProvider, IIdProvider
Inheritance:
object object
Derived:
DotNetAstNodeId JavaScriptAstNodeId PythonAstNodeId XmlAstNodeId
Implements:
IAstNodeIdProvider IIdProvider

Constructors

AstNodeIdProviderBase()

Initializes an instance of the class.

protected AstNodeIdProviderBase()

Properties

MaxId

The maximum ID returned by this provider.

public abstract int MaxId { get; }

Property Value

int

MinId

The minimum ID returned by this provider.

public abstract int MinId { get; }

Property Value

int

Methods

ContainsId(int)

Returns whether the specified ID value is valid for this ID provider.

public abstract bool ContainsId(int id)
Parameter Type Description
id int

The ID to examine.

Returns

bool:

true if the ID value is valid; otherwise, false

GetDescription(int)

Returns the actual string representation for the specified ID.

public abstract string? GetDescription(int id)
Parameter Type Description
id int

The ID to examine.

Returns

string

GetKey(int)

Returns the string-based key for the specified ID.

public abstract string? GetKey(int id)
Parameter Type Description
id int

The ID to examine.

Returns

string

Inherited Members

Extension Methods