Options
All
  • Public
  • Public/Protected
  • All
Menu

Lexer class

Hierarchy

  • Lexer

Index

Constructors

constructor

  • new Lexer(src: string): Lexer

Properties

Private _keyword

_keyword: Token

Keyword index amounts to

Private _prev

_prev: number

Previous valid source index

Private _value

_value: string

Entire value an index amounts to

Private si

si: number

Source index, or the current character index to lex

Private src

src: string

Source to tokenize

Accessors

keyword

prev

  • get prev(): number

value

  • get value(): string

Methods

Private annotation

  • annotation(): boolean

Private digit

  • digit(radix: number): number

Private escape

  • escape(): string

Private identifier

isAlpha

  • isAlpha(char: string): boolean

isAlphaNum

  • isAlphaNum(char: string): boolean

isDigit

  • isDigit(char: string): boolean

isHexDigit

  • isHexDigit(char: string): boolean

isWhite

  • isWhite(char: string): boolean

Private jsonObject

  • jsonObject(startKey: string, endKey: string): Token

Private lineComment

Private matchChar

  • matchChar(char: string): boolean

Private matchIf

  • matchIf(pred: (string: string) => boolean): boolean

Private matchWhile

  • matchWhile(pred: (string: string) => boolean): boolean

next

Private number

Private quotedString

  • quotedString(quote: string): Token

Private setValue

  • setValue(): void

Private whitespace

Generated using TypeDoc