import { Camera } from "./camera.ts"; import { Chime } from "./chime.ts"; import type { DeviceContext } from "./context.ts"; import { Fob } from "./fob.ts"; import { Light } from "./light.ts"; import { Nvr } from "./nvr.ts"; import { Relay } from "./relay.ts"; import { Sensor } from "./sensor.ts"; import { Viewer } from "./viewer.ts"; /** * The projection factory the client composes. It turns ids into live {@link DeviceProjection} handles for every device category - looked up by id or iterated as a * collection against the current store snapshot - plus the id-free NVR singleton handle. This is where projection construction lives - at Layer 3 - so `StateStore` * stays a pure generic engine that never imports a device type. * * Projections are not cached: each lookup or iteration mints fresh handles. That is intentional and cheap - a handle is a thin `(context, id)` view, and identity is * meaningless for a value that simply reads through to the single source of truth. * * @category Devices */ export declare class DeviceRegistry { #private; constructor(ctx: DeviceContext); /** Look up a camera by id, or `undefined` when no such camera is in the current state. */ camera(id: string): Camera | undefined; /** Look up a chime by id, or `undefined` when absent. */ chime(id: string): Chime | undefined; /** Look up a fob by id, or `undefined` when absent. */ fob(id: string): Fob | undefined; /** Look up a light by id, or `undefined` when absent. */ light(id: string): Light | undefined; /** Look up a relay by id, or `undefined` when absent. */ relay(id: string): Relay | undefined; /** Look up a sensor by id, or `undefined` when absent. */ sensor(id: string): Sensor | undefined; /** Look up a viewer by id, or `undefined` when absent. */ viewer(id: string): Viewer | undefined; /** * The NVR singleton projection. Unlike the device lookups there is no id and no `undefined`: the NVR is a singleton, so this always returns a handle. Its getters throw * before the first bootstrap (when the NVR record is not yet known) - the same absent-record contract a device projection uses. A connected client never hits it. */ nvr(): Nvr; /** Every camera in the current state, as live projections. */ cameras(): readonly Camera[]; /** Every chime in the current state, as live projections. */ chimes(): readonly Chime[]; /** Every fob in the current state, as live projections. */ fobs(): readonly Fob[]; /** Every light in the current state, as live projections. */ lights(): readonly Light[]; /** Every relay in the current state, as live projections. */ relays(): readonly Relay[]; /** Every sensor in the current state, as live projections. */ sensors(): readonly Sensor[]; /** Every viewer in the current state, as live projections. */ viewers(): readonly Viewer[]; } //# sourceMappingURL=registry.d.ts.map