homebridge-roborock-control
Version:
A Homebridge plugin to control Roborock vacuum cleaners.
19 lines (18 loc) • 865 B
TypeScript
import { PlatformAccessory } from 'homebridge';
import { PlatformPlugin } from 'homebridge/lib/api.js';
/**
* Base class to implement common polling functionality for accessories.
*/
export declare class PollingAccessory<DeviceState> {
protected readonly platform: PlatformPlugin;
protected readonly accessory: PlatformAccessory;
protected readonly refreshInterval: number;
protected static readonly kDefaultRefreshInterval = 10000;
private _currentState;
constructor(platform: PlatformPlugin, accessory: PlatformAccessory, refreshInterval?: number);
protected refreshDeviceState(): Promise<void>;
protected currentState(): DeviceState;
protected servicesReady(): boolean;
protected getDeviceState(lastState: DeviceState): Promise<DeviceState>;
protected updateHomekitState(currentState: DeviceState): Promise<void>;
}