/** * @license * Copyright 2022-2026 Matter.js Authors * SPDX-License-Identifier: Apache-2.0 */ import type { ClientGroup } from "#node/ClientGroup.js"; import type { ClientNode } from "#node/ClientNode.js"; import { Construction, StorageContext } from "@matter/general"; import { ClientNodeStore } from "./ClientNodeStore.js"; /** * Manages {@link ClientNodeStore}s for a {@link Node}. */ export declare class ClientNodeStores { #private; get construction(): Construction; constructor(storage: StorageContext); [Construction.construct](): Promise; /** * Allocate a local ID for a peer. * * The ID may be preassigned or we will assign using an incrementing sequential number. The number is reserved for * the life of this process or, if data is persisted, until erased. * * The ID is not an identity that outlives the peer. The counter starts from the IDs already in storage, so once a * peer is removed and its data is gone, a peer commissioned later may receive the same ID. Anything stored for * longer than the peer itself cannot rely on either identifier. A `PeerAddress` names one device only for as long as * that device stays commissioned. Past that it may be issued to another device under the rules * `ControllerBehavior.allocatePeerAddress` documents, and a lookup can then name that other device. */ allocateId(): string; /** * Get the store for a single {@link ClientNode} or peer Id. * * These stores are cached internally by Id. */ storeForNode(nodeOrId: ClientNode | string): ClientNodeStore; storeForGroup(node: ClientGroup): ClientNodeStore; /** * List all nodes present. */ get knownIds(): string[]; /** * Discard all persisted node data. The collection remains usable and IDs are reassigned from the start. */ erase(): Promise; close(): Promise; } //# sourceMappingURL=ClientNodeStores.d.ts.map