Class ParserRuleInvocationDescriptor
Describes passive metadata associated with a parser rule invocation. The descriptor preserves grammar metadata for observation only and does not bind, allocate, propagate, or execute rule-level metadata.
public sealed class ParserRuleInvocationDescriptor
- Inheritance
-
ParserRuleInvocationDescriptor
- Inherited Members
- Extension Methods
Properties
Exceptions
Gets passive exception metadata descriptors declared by the parser rule.
public IReadOnlyList<ParserRuleExceptionDescriptor> Exceptions { get; init; }
Property Value
Locals
Gets passive local descriptors declared by the parser rule.
public IReadOnlyList<ParserRuleLocalDescriptor> Locals { get; init; }
Property Value
Options
Gets passive rule option metadata keyed by option name.
public IReadOnlyDictionary<string, string> Options { get; init; }
Property Value
Parameters
Gets passive parameter descriptors declared by the parser rule.
public IReadOnlyList<ParserRuleParameterDescriptor> Parameters { get; init; }
Property Value
RawLocals
Gets the raw locals metadata text when it is available in the parser model.
public string? RawLocals { get; init; }
Property Value
RawParameters
Gets the raw parameter metadata text when it is available in the parser model.
public string? RawParameters { get; init; }
Property Value
RawReturnType
Gets the raw return metadata text when it is available in the parser model.
public string? RawReturnType { get; init; }
Property Value
Returns
Gets passive return descriptors declared by the parser rule.
public IReadOnlyList<ParserRuleReturnDescriptor> Returns { get; init; }
Property Value
RuleName
Gets the parser rule name associated with the invocation.
public required string RuleName { get; init; }
Property Value
Methods
FromRule(Rule)
Creates a passive invocation descriptor from the metadata currently exposed by a parser rule.
public static ParserRuleInvocationDescriptor FromRule(Rule rule)
Parameters
ruleRuleParser rule whose available metadata should be described.
Returns
- ParserRuleInvocationDescriptor
A passive descriptor containing only currently represented rule metadata.