UNPKG

fracturedjsonjs

Version:

JSON formatter that produces highly readable but fairly compact output

26 lines (25 loc) 1.06 kB
import { FracturedJsonOptions } from "./FracturedJsonOptions"; import { JsonItem } from "./JsonItem"; export declare class Parser { Options: FracturedJsonOptions; ParseTopLevel(inputJson: string, stopAfterFirstElem: boolean): JsonItem[]; private ParseTopLevelFromEnum; private ParseItem; private ParseSimple; /** * Parse the stream of tokens into a JSON array (recursively). The enumerator should be pointing to the open * square bracket token at the start of the call. It will be pointing to the closing bracket when the call * returns. */ private ParseArray; /** * Parse the stream of tokens into a JSON object (recursively). The enumerator should be pointing to the open * curly bracket token at the start of the call. It will be pointing to the closing bracket when the call * returns. */ private ParseObject; private static ItemTypeFromTokenType; private static GetNextTokenOrThrow; private static IsMultilineComment; private static AttachObjectValuePieces; }