Class Grammar

Hierarchy

  • Grammar

Constructors

Properties

content: string

Literal content, or T/NT's type name.

name: string

The name of the grammar. By default the value is equal to this.content. The name is only used in ASTNode query selector.

node?: Readonly<ASTNode<any>>

Cache the temporary ast node.

str?: string

Cache the string representation.

Methods

  • This function is used to create temporary ASTNode for comparison. Lexer is used to parse literal value's type name. The result will be cached to prevent duplicated calculation.

    Parameters

    Returns Readonly<ASTNode<any>>

Generated using TypeDoc