/** * @license * Copyright 2022-2026 Matter.js Authors * SPDX-License-Identifier: Apache-2.0 */ import type { Endpoint } from "#endpoint/Endpoint.js"; import type { StorageContext } from "@matter/general"; import { ServerEndpointStore } from "./ServerEndpointStore.js"; /** * Manages {@link ServerEndpointStore}s for a {@link ServerNode}. */ export declare class ServerEndpointStores { #private; load(storage: StorageContext): Promise; erase(): Promise; close(): Promise; /** * Allocate an endpoint number. * * Either allocates a new number for a {@link Endpoint} or reserves the endpoint's number. If the {@link Endpoint} * already has a number but it is allocated to a different endpoint it is an error. * * We must persist the assigned number and next endpoint number. We are fairly resilient to the small chance that * persistence fails so we persist lazily and return synchronously. */ assignNumber(endpoint: Endpoint): void; /** * Obtain the store for a single {@link Endpoint}. * * These stores are cached internally by ID. */ storeForEndpoint(endpoint: Endpoint): ServerEndpointStore; /** * Deactivate the store for a single {@link Endpoint}. This puts the endpoint number back into pre-allocated state */ deactivateStoreForEndpoint(endpoint: Endpoint): void; /** * Erase storage for a single {@link Endpoint}. */ eraseStoreForEndpoint(endpoint: Endpoint): Promise; } //# sourceMappingURL=ServerEndpointStores.d.ts.map