Table of Contents

Class ParserRuleCallExecutionContext

Namespace
Utils.Parser.Runtime
Assembly
Utils.Parser.dll

Carries passive metadata for an explicit parser rule-call execution policy invocation. Raw arguments are split syntactically only. The parser does not evaluate or bind them automatically; an explicitly installed policy may request an atomic managed seed batch through TrySetParameterSeeds(IReadOnlyDictionary<string, object?>).

public sealed class ParserRuleCallExecutionContext
Inheritance
ParserRuleCallExecutionContext
Inherited Members
Extension Methods

Properties

CallerFrame

Gets the caller invocation frame that was current when the rule call began, when frame tracking is enabled. Policies must not treat the mutable frame as rollback-managed external state or retain it beyond the callback.

public required ParserRuleInvocationFrame? CallerFrame { get; init; }

Property Value

ParserRuleInvocationFrame

CompletedCallResult

Gets the annotated completed child-call result after a successful call when invocation-frame tracking is enabled.

public ParserRuleCallResult? CompletedCallResult { get; }

Property Value

ParserRuleCallResult

LabelKind

Gets the label kind from the current call site.

public ParserRuleReferenceLabelKind LabelKind { get; init; }

Property Value

ParserRuleReferenceLabelKind

LabelName

Gets the optional label name from the current call site.

public string? LabelName { get; init; }

Property Value

string

NamedRawArguments

Gets syntactically split named raw arguments when every top-level argument has a supported name separator; otherwise, gets null. Values remain uninterpreted source text.

public IReadOnlyDictionary<string, string>? NamedRawArguments { get; init; }

Property Value

IReadOnlyDictionary<string, string>

PositionalRawArguments

Gets syntactically split positional raw arguments when an argument clause is present. Values remain uninterpreted source text.

public IReadOnlyList<string>? PositionalRawArguments { get; init; }

Property Value

IReadOnlyList<string>

RawArguments

Gets the uninterpreted raw argument text from the current call site, without outer brackets.

public string? RawArguments { get; init; }

Property Value

string

RuleName

Gets the target parser rule name.

public required string RuleName { get; init; }

Property Value

string

Succeeded

Gets whether the target parser rule produced a parse node.

public bool Succeeded { get; }

Property Value

bool

TargetRuleDescriptor

Gets passive metadata for the target parser rule.

public ParserRuleInvocationDescriptor? TargetRuleDescriptor { get; init; }

Property Value

ParserRuleInvocationDescriptor

Methods

TrySetParameterSeed(string, object?)

Attempts to seed one parameter for the current target rule through managed pending-child state. The caller cannot select a different target rule through this API.

public bool TrySetParameterSeed(string parameterName, object? value)

Parameters

parameterName string

Declared target parameter name.

value object

Untyped value to seed, including null.

Returns

bool

true when managed seeding is available; otherwise, false.

TrySetParameterSeeds(IReadOnlyDictionary<string, object?>)

Attempts to atomically seed multiple parameters for the current target rule through managed pending-child state. The caller cannot select a different target rule through this API, and implementations must retain all values or none.

public bool TrySetParameterSeeds(IReadOnlyDictionary<string, object?> values)

Parameters

values IReadOnlyDictionary<string, object>

Declared target parameter names and their untyped values, including null.

Returns

bool

true when every seed was retained atomically; otherwise, false.