Class AbstractLangiumParserAbstract

Base interface for all parsers. Mainly used by the parser-builder-base.ts to perform work on different kinds of parsers. The main use cases are:

  • AST parser: Based on a string, create an AST for the current grammar
  • Completion parser: Based on a partial string, identify the current position of the input within the grammar

Hierarchy (view full)

Implements

Constructors

Properties

_unorderedGroups: Map<string, boolean[]> = ...
allRules: Map<string, RuleResult> = ...
lexer: Lexer
mainRule: RuleResult
wrapper: ChevrotainWrapper

Accessors

Methods

  • Whether the parser is currently actually in use or in "recording mode". Recording mode is activated once when the parser is analyzing itself. During this phase, no input exists and therefore no AST should be constructed

    Returns boolean