1 | import { MacAddress } from "../../types";
|
2 | import { SerializableController } from "../controller";
|
3 | import { Accessory } from "../Accessory";
|
4 |
|
5 |
|
6 |
|
7 | export declare class ControllerStorage {
|
8 | private readonly accessoryUUID;
|
9 | private initialized;
|
10 | private username?;
|
11 | private fileCreated;
|
12 | purgeUnidentifiedAccessoryData: boolean;
|
13 | private trackedControllers;
|
14 | private controllerData;
|
15 | private restoredAccessories?;
|
16 | private parent?;
|
17 | private linkedAccessories?;
|
18 | private queuedSaveTimeout?;
|
19 | private queuedSaveTime?;
|
20 | constructor(accessory: Accessory);
|
21 | private enqueueSaveRequest;
|
22 | /**
|
23 | * Links a bridged accessory to the ControllerStorage of the bridge accessory.
|
24 | *
|
25 | * @param accessory
|
26 | */
|
27 | linkAccessory(accessory: Accessory): void;
|
28 | trackController(controller: SerializableController): void;
|
29 | untrackController(controller: SerializableController): void;
|
30 | purgeControllerData(controller: SerializableController): void;
|
31 | private handleStateChange;
|
32 | private restoreController;
|
33 | /**
|
34 | * Called when this particular Storage object is feed with data loaded from disk.
|
35 | * This method is only called once.
|
36 | *
|
37 | * @param data - array of {@link StoredControllerData}. undefined if nothing was stored on disk for this particular storage object
|
38 | */
|
39 | private init;
|
40 | load(username: MacAddress): void;
|
41 | save(): void;
|
42 | static persistKey(username: MacAddress): string;
|
43 | static remove(username: MacAddress): void;
|
44 | }
|
45 |
|
\ | No newline at end of file |