import { IParserDiagnostic } from './diagnostics'; import { AnyType, ISchemaNode } from './nodes'; import { CoreSchemaMetaSchema } from './schema'; import { JSONSchema7Definition } from './types'; interface ParserCompileOptions { /** * The type name for schemas that are functionally equivalent to TypeScript's `any` * or `unknown` type. */ anyType?: AnyType; /** * Skip emitting a `@see` directive when generating doc comments on schemas having * an `$id` property. */ omitIdComments?: boolean; /** * Declaration options for the top-level schemas in each added schema file. */ topLevel?: ParserCompileTypeOptions; /** * Declaration options for the sub-schemas depended-upon by the top-level schemas. */ lifted?: ParserCompileTypeOptions; shouldOmitTypeEmit?(node: ISchemaNode, parentNode: ISchemaNode): boolean; } interface ParserCompileTypeOptions { hasDeclareKeyword?: boolean; isExported?: boolean; } interface AddSchemaOptions { preferredName?: string; } export interface ParserOptions { /** * Specify the default schema to be used for unknown properties. * * For example, you could pass the schema `true` which will allow any valid * JSON value to be used as an unknown property. */ defaultUnknownPropertiesSchema?: JSONSchema7Definition; } export declare class Parser { private readonly ctx; private readonly uriToTypeName; private readonly uriByTypeName; private readonly rootNodes; constructor(options?: ParserOptions); addSchema(uri: string, schema: JSONSchema7Definition, options?: AddSchemaOptions): string; compile(options?: ParserCompileOptions): { diagnostics: IParserDiagnostic[]; text: string; }; private checkReferences; private generateDeconflictedName; private getNodeByReference; private generateTypings; } export {}; //# sourceMappingURL=parser.d.ts.map