Class ParserEmbeddedCodeTransformationContext
- Namespace
- Utils.Parser.Diagnostics.EmbeddedCode
- Assembly
- Utils.Parser.Diagnostics.dll
Context supplied to embedded-code transformers.
public sealed class ParserEmbeddedCodeTransformationContext
- Inheritance
-
ParserEmbeddedCodeTransformationContext
- Inherited Members
- Extension Methods
Properties
Code
Gets the raw embedded code exactly as represented by the grammar parser.
public string Code { get; set; }
Property Value
EmptyLabels
Gets an empty label map shared by default contexts.
public static IReadOnlyDictionary<string, ParserEmbeddedRuleLabelDescriptor> EmptyLabels { get; }
Property Value
GrammarName
Gets the owning grammar name when available.
public string? GrammarName { get; set; }
Property Value
Labels
Gets parser rule-reference labels visible to the code block.
public IReadOnlyDictionary<string, ParserEmbeddedRuleLabelDescriptor> Labels { get; set; }
Property Value
Locals
Gets passive local metadata visible to the code block.
public IReadOnlyList<ParserEmbeddedRuleDeclarationDescriptor> Locals { get; set; }
Property Value
Location
Gets the grammar location that owns the embedded code.
public ParserEmbeddedCodeLocation Location { get; set; }
Property Value
Parameters
Gets passive parameter metadata visible to the code block.
public IReadOnlyList<ParserEmbeddedRuleDeclarationDescriptor> Parameters { get; set; }
Property Value
Returns
Gets passive return metadata visible to the code block.
public IReadOnlyList<ParserEmbeddedRuleDeclarationDescriptor> Returns { get; set; }
Property Value
RuleName
Gets the owning parser rule name when available.
public string? RuleName { get; set; }