import type { GoveePlatform } from '../platform.js'; import type { GoveePlatformAccessoryWithControl } from '../types.js'; import type { GoveeDeviceBase } from './base.js'; import type { DeviceModelDefinition } from '../catalog/index.js'; export type DeviceHandlerClass = new (platform: GoveePlatform, accessory: GoveePlatformAccessoryWithControl) => GoveeDeviceBase; export type DeviceCategory = 'light' | 'lightSwitch' | 'outletSingle' | 'outletDouble' | 'outletTriple' | 'switchSingle' | 'switchDouble' | 'switchTriple' | 'fan' | 'heater' | 'heater1b' | 'cooler' | 'humidifier' | 'dehumidifier' | 'purifier' | 'diffuser' | 'kettle' | 'iceMaker' | 'sensorThermo' | 'sensorThermo4' | 'sensorThermoSwitch' | 'sensorLeak' | 'sensorContact' | 'sensorPresence' | 'sensorButton' | 'sensorMonitor' | 'tap' | 'valve' | 'tv' | 'template'; /** * Register a device handler class for a category */ export declare function registerDeviceHandler(category: DeviceCategory, handler: DeviceHandlerClass): void; /** * Register model numbers for a category */ export declare function registerModelsForCategory(category: DeviceCategory, models: readonly string[]): void; /** * Register a device handler for a specific model (takes priority over category) */ export declare function registerModelHandler(model: string, handler: DeviceHandlerClass): void; /** * Get the device category for a model number */ export declare function getCategoryForModel(model: string): DeviceCategory | undefined; /** * Get the device handler class for a category */ export declare function getDeviceHandler(category: DeviceCategory): DeviceHandlerClass | undefined; /** * Get the device handler class for a model number. * Model-specific handlers take priority over category handlers. */ export declare function getDeviceHandlerForModel(model: string): DeviceHandlerClass | undefined; /** * Create a device instance for the given model */ export declare function createDeviceInstance(model: string, platform: GoveePlatform, accessory: GoveePlatformAccessoryWithControl): GoveeDeviceBase | undefined; /** * Initialize the model to category mappings from constants */ export declare function initializeModelMappings(): void; /** * Get all registered categories */ export declare function getRegisteredCategories(): DeviceCategory[]; /** * Check if a model is supported */ export declare function isModelSupported(model: string): boolean; /** * Get the device definition from the catalog for a model */ export declare function getModelDefinition(model: string): DeviceModelDefinition | undefined; /** * Check if a model has a specific capability in the catalog */ export declare function modelHasCapability(model: string, capability: keyof DeviceModelDefinition['capabilities']): boolean; /** * Get the speed configuration for a model from the catalog */ export declare function getModelSpeedConfig(model: string): DeviceModelDefinition['capabilities']['speed']; declare const _default: { registerDeviceHandler: typeof registerDeviceHandler; registerModelsForCategory: typeof registerModelsForCategory; registerModelHandler: typeof registerModelHandler; getCategoryForModel: typeof getCategoryForModel; getDeviceHandler: typeof getDeviceHandler; getDeviceHandlerForModel: typeof getDeviceHandlerForModel; createDeviceInstance: typeof createDeviceInstance; initializeModelMappings: typeof initializeModelMappings; getRegisteredCategories: typeof getRegisteredCategories; isModelSupported: typeof isModelSupported; getModelDefinition: typeof getModelDefinition; modelHasCapability: typeof modelHasCapability; getModelSpeedConfig: typeof getModelSpeedConfig; }; export default _default;