UNPKG

homebridge-homeconnect

Version:

A Homebridge plugin that connects Home Connect appliances to Apple HomeKit

64 lines 3.9 kB
import { Characteristic, Service } from 'homebridge'; import { ApplianceBase } from './appliance-generic.js'; import { Constructor } from './utils.js'; import { ProgramKey } from './api-value-types.js'; export interface ACProgram { auto: boolean; manual: boolean; } export interface UpdateFanACHCValue { active?: number; auto?: number; percent?: number; } export declare function HasFanAC<TBase extends Constructor<ApplianceBase>>(Base: TBase): { new (...args: any[]): { readonly activeService: Service; acPrograms: Map<ProgramKey, ACProgram>; initHasFan(): Promise<void>; addFan(updateHC: (value?: UpdateFanACHCValue) => Promise<void>): void; updateFanHC({ active, auto, percent }: UpdateFanACHCValue): Promise<void>; setFan(active: boolean, auto: boolean, percent: number): Promise<void>; readonly Service: typeof Service; readonly Characteristic: typeof Characteristic; readonly config: import("./config-types.js").ApplianceConfig; readonly schema: import("./homebridge-ui/schema-data.js").ConfigSchemaData; readonly optionalFeatures: import("./homebridge-ui/schema-data.js").SchemaOptionalFeature[]; readonly cache: import("./persist-cache.js").PersistCache; readonly cachedOperation: Record<string, string>; readonly cachedPromise: Map<string, Promise<unknown>>; readonly asyncInitTasks: { name: string; promise: Promise<void>; }[]; serviceNames: import("./service-name.js").ServiceNames; readonly accessoryInformationService: Service; readonly obsoleteServices: Service[]; readonly log: import("homebridge").Logger; readonly platform: import("./platform.js").HomeConnectPlatform; readonly device: import("./homeconnect-device.js").HomeConnectDevice; readonly accessory: import("homebridge").PlatformAccessory; asyncInitialise(name: string, promise: Promise<void>): void; waitAsyncInitialisation(): Promise<void>; makeService(serviceConstructor: typeof Service & { new (displayName?: string, subtype?: string): Service; UUID: string; }, suffix?: string, subtype?: string): Service; cleanupServices(): void; cleanupOldVersions(): void; unregister(): void; identify(): Promise<void>; hasOptionalFeature(service: string, name: string, group?: string, enableByDefault?: boolean): boolean; setOptionalFeatures(): void; getCached<Type>(key: string, operation: () => Promise<Type>): Promise<Type>; doCachedOperation<Type>(key: string, operation: () => Promise<Type>): Promise<Type>; makeSerialised<Value extends import("./serialised.js").SerialisedValue, Returns = void>(operation: import("./serialised.js").SerialisedOperation<Value, Returns>, defaultValue?: Value): (value?: Value) => Promise<Returns>; makeSerialisedObject<Value extends object, Returns = void>(operation: import("./serialised.js").SerialisedOperation<Value, Returns>): (value?: Value) => Promise<Returns>; onSet<Type>(handler: import("./appliance-generic.js").OnSetHandler<Type>, assertIsType: (value: unknown) => asserts value is Type): import("homebridge").CharacteristicSetHandler; onSetBoolean(handler: import("./appliance-generic.js").OnSetHandler<boolean>): import("homebridge").CharacteristicSetHandler; onSetNumber(handler: import("./appliance-generic.js").OnSetHandler<number>): import("homebridge").CharacteristicSetHandler; onSetString(handler: import("./appliance-generic.js").OnSetHandler<string>): import("homebridge").CharacteristicSetHandler; trap<Type>(when: string, promise: Promise<Type> | Type, canThrow?: boolean): Promise<Type | undefined>; }; } & TBase; //# sourceMappingURL=has-fan-ac.d.ts.map