/** * @license * Copyright 2022-2026 Matter.js Authors * SPDX-License-Identifier: Apache-2.0 */ import { FeatureSet, Model, ModelIndex, Schema, Scope, ValueModel } from "@matter/model"; import { AccessControl } from "@matter/protocol"; import { AttributeId } from "@matter/types"; import type { ValReference } from "../state/managed/ValReference.js"; import { ValueSupervisor } from "./ValueSupervisor.js"; /** * A RootSupervisor is a {@link ValueSupervisor} that supervises a specific root {@link Schema}. It acts as a factory * for {@link ValueSupervisor}s for sub-schemas of the root schema. * * You can produce a ValueSupervisor for any schema using this factory. However, there are specific customizations * controlled by the root schema: * * - Change eventing occur for root schema members. In the case of a cluster this means you can monitor for changes on * a per-attribute basis. * * - If the root schema defines a cluster, the cluster's featureMap and supportedFeatures affect conformance-based * validation. */ export declare class RootSupervisor implements ValueSupervisor { #private; /** * Create a new supervisor. * * @param schema the {@link Schema} for the supervised data */ constructor(schema: Schema); /** * Obtain the supervisor for schema. The result is cached. */ static for(schema: T): T extends undefined ? RootSupervisor | undefined : RootSupervisor; get owner(): RootSupervisor; get schema(): Schema; get scope(): Scope; get access(): AccessControl; get validate(): ValueSupervisor.Validate | undefined; get manage(): ValueSupervisor.Manage; get patch(): ValueSupervisor.Patch; get cast(): ValueSupervisor.Cast; /** * The names of all members. */ get memberNames(): Set; /** * Retrieve names or IDs of fields configured as non-volatile. */ persistentKeys(primaryKey?: ValReference.PrimaryKey): Set; get propertyNamesAndIds(): Map; /** * Reverse of {@link propertyNamesAndIds}: maps attribute ID strings to property names. */ get propertyIdsAndNames(): Map; /** * Retrieve members for schema in {@link scope}. * * The {@link Scope.ConformanceMode} defaults to "deconflicted" if you do not override. */ membersOf(schema: T, options?: Scope.MemberOptions): ModelIndex>; /** * All available features defined in the schema. */ get featureMap(): ValueModel; /** * Features supported by this implementation. */ get supportedFeatures(): FeatureSet; /** * Obtain {@link ValueSupervisor} implementation for a specific schema. * * @param schema the model describing the record type * @returns the I/O implementation */ get(schema: Schema): ValueSupervisor; } //# sourceMappingURL=RootSupervisor.d.ts.map