import { Token } from './tokens'; /** * Output of the parser. */ export interface ParserOutput { /** * All the tokens that are not flags or options, in order. */ ordered: Token[]; /** * The parsed flags. */ flags: Set; /** * The parsed options mapped to their value. */ options: Map; } /** * Creates an empty parser output. * @returns An empty output. */ export declare function emptyOutput(): ParserOutput; /** * Merges multiple outputs into one. * Flags and options that appear later will be preferred if there are duplicates. * @param ps - The outputs to merge. * @returns The merged output. */ export declare function mergeOutputs(...ps: ParserOutput[]): ParserOutput; /** * Converts an output to JSON, where the flags and options are turned into arrays of entries. * You can recover the output with 'outputFromJSON'. * @param p - The output. * @returns The JSON. */ export declare function outputToJSON(p: ParserOutput): Record; /** * Converts JSON to a parser output. * @param obj - A valid JSON input, following the schema from 'outputToJSON'. * @returns The output. */ export declare function outputFromJSON(obj: Record): ParserOutput;