/**
 * @license
 * Copyright 2022-2026 Matter.js Authors
 * SPDX-License-Identifier: Apache-2.0
 */
import type { ClusterModel } from "#models/ClusterModel.js";
import { DatatypeModel } from "#models/DatatypeModel.js";
import type { Model } from "#models/Model.js";
import type { ValueModel } from "#models/ValueModel.js";
/**
 * Matter data structure semantics
 *
 * Here we use the term "schema" to mean any model element that defines a datatype.  For schema we allow any Matter
 * model for such an element.
 *
 * Most schema is a {@link ValueModel} which explicitly models data. {@link ClusterModel} is also valid schema.
 *
 * You will see references to "structs" and "lists" throughout our code. These are Matter's two container types and map
 * to JS objects and arrays respectively.  Thus we tend to use struct/object and list/array interchangeably.
 *
 * If schema is a {@link ClusterModel}, it models a struct with attributes as fields.
 *
 * Schema is immutable and cannot change moving forward.
 */
export type Schema = ClusterModel | ValueModel;
/**
 * Obtain {@link Schema} for a {@link Schema.Source} if present.
 */
export declare function Schema(source: Schema.Source): Schema.Struct | undefined;
export declare namespace Schema {
    /**
     * Schema that defines an object with named properties.
     */
    type Struct = ClusterModel | DatatypeModel;
    /**
     * Schema that defines a cluster.
     */
    type Cluster = ClusterModel;
    /**
     * Obtain {@link Schema} that is required for operation.
     */
    function Required(source: Model.Source): Struct;
    type Source = Schema | NewableFunction | object;
    /**
     * Associate schema with an arbitrary object (class constructor or enum object).
     *
     * The factory form enables lazy resolution — the factory is invoked on first access and the result cached.
     */
    function set(target: object, source: ValueModel | (() => ValueModel)): void;
    const empty: DatatypeModel;
}
//# sourceMappingURL=Schema.d.ts.map