/** * @license * Copyright 2022-2026 Matter.js Authors * SPDX-License-Identifier: Apache-2.0 */ import { EndpointComposition } from "../../common/EndpointComposition.js"; import { ClusterModel, ConditionModel, DeviceTypeModel, MatterModel, Model, RequirementModel } from "../../models/index.js"; /** * The lookups {@link model} shares with every `DeviceTypeValidationPass` resolved in it, one instance per model: * resolving a requirement to the cluster, feature or element it names, a device type's conditions, and similar. A * tree-derived fact never belongs here. * * Keyed on the model instance, so a model built by {@link MatterModel.withClusters} never sees another model's * entries. * * @internal */ export declare function lookupsFor(model: MatterModel): ModelLookups; /** * The declared names a requirement's conformance may reference. * * @internal */ export interface KnownNames { /** * The conditions reachable unqualified from the requirement's {@link RequirementResolver.EndpointScope} and the * features of its cluster. A name outside them leaves the requirement unjudged. */ all: Set; /** * The features of the requirement's cluster. */ features: Set; } /** * @internal */ declare class ModelLookups { #private; constructor(model: MatterModel); /** * The device type {@link id} names, undefined when the model does not define one. */ deviceTypeOf(id: number): DeviceTypeModel | undefined; /** * The requirements {@link parent}, a device type or a requirement, states directly. */ requirementsOf(parent: DeviceTypeModel | RequirementModel): readonly RequirementModel[]; /** * The component device type {@link requirement} names, undefined when it is no device type requirement or names * no device type of the model. */ componentOf(requirement: RequirementModel): DeviceTypeModel | undefined; /** * Whether {@link deviceType} states a device type requirement, which makes its endpoints composed. */ componentsDeclaredBy(deviceType: DeviceTypeModel): boolean; /** * {@link DeviceTypeModel.effectiveComposition}, resolved once per device type. */ compositionOf(deviceType: DeviceTypeModel): EndpointComposition; /** * The cluster {@link requirement} names, undefined when it does not resolve in the model. */ clusterOf(requirement: RequirementModel): ClusterModel | undefined; /** * The feature, attribute, command or event model {@link requirement} names, undefined when it does not resolve. */ referentOf(requirement: RequirementModel): Model | undefined; /** * The condition {@link requirement} asserts, undefined when it asserts none. */ assertedConditionOf(requirement: RequirementModel): ConditionModel | undefined; /** * {@link RequirementResolver.conditionsOf}, resolved once per model and device type. */ conditionScopeOf(deviceType: DeviceTypeModel): Map; /** * The declared names {@link requirement}'s conformance may reference. */ knownNamesOf(requirement: RequirementModel): KnownNames; /** * The device types the model classifies as Base, whose requirements apply to every endpoint that lists a device * type the model defines. */ get baseDeviceTypes(): readonly DeviceTypeModel[]; /** * The names of the conditions a requirement of a device type of the model asserts. */ get assertedConditionNames(): ReadonlySet; /** * The names {@link requirement}'s conformance references, qualified ones joined by dots. */ conformanceNamesOf(requirement: RequirementModel): ReadonlySet; /** * The Aggregator device type, undefined when the model does not define one. */ get aggregator(): DeviceTypeModel | undefined; /** * The BridgedNode device type, undefined when the model does not define one. */ get bridgedNode(): DeviceTypeModel | undefined; } export {}; //# sourceMappingURL=ModelLookups.d.ts.map