/*!
 * Copyright (c) Microsoft Corporation and contributors. All rights reserved.
 * Licensed under the MIT License.
 */
import { Static } from "@sinclair/typebox";
import { FieldKey, TreeStoredSchema, TreeNodeSchemaIdentifier, ValueSchema } from "../core";
import { ICodecOptions, IJsonCodec } from "../codec";
/**
 * Format for encoding as json.
 *
 * For consistency all lists are sorted and undefined values are omitted.
 *
 * This chooses to use lists of named objects instead of maps:
 * this choice is somewhat arbitrary, but avoids user data being used as object keys,
 * which can sometimes be an issue (for example handling that for "__proto__" can require care).
 */
export declare const Format: import("@sinclair/typebox").TObject<{
    version: import("@sinclair/typebox").TLiteral<"1.0.0">;
    nodeSchema: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
        name: import("@sinclair/typebox").TUnsafe<TreeNodeSchemaIdentifier<string>>;
        objectNodeFields: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TObject<{
            name: import("@sinclair/typebox").TUnsafe<FieldKey>;
            kind: import("@sinclair/typebox").TUnsafe<import("../core").FieldKindIdentifier>;
            types: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnsafe<TreeNodeSchemaIdentifier<string>>>>;
        }>>;
        mapFields: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
            kind: import("@sinclair/typebox").TUnsafe<import("../core").FieldKindIdentifier>;
            types: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnsafe<TreeNodeSchemaIdentifier<string>>>>;
        }>>;
        leafValue: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TEnum<typeof ValueSchema>>;
    }>>;
    rootFieldSchema: import("@sinclair/typebox").TObject<{
        kind: import("@sinclair/typebox").TUnsafe<import("../core").FieldKindIdentifier>;
        types: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TUnsafe<TreeNodeSchemaIdentifier<string>>>>;
    }>;
}>;
export type Format = Static<typeof Format>;
export declare function encodeRepo(repo: TreeStoredSchema): Format;
/**
 * Creates a codec which performs synchronous monolithic encoding of schema content.
 *
 * TODO: when perf matters, this should be replaced with a chunked async version using a binary format.
 */
export declare function makeSchemaCodec({ jsonValidator: validator, }: ICodecOptions): IJsonCodec<TreeStoredSchema, Format>;
//# sourceMappingURL=schemaIndexFormat.d.ts.map