import type { Clock } from '../ports/clock.js'; import type { CommandRunner } from '../ports/command-runner.js'; import type { Logger } from '../ports/logger.js'; import type { CommandSpec } from '../command/command-spec.js'; import type { OnOffParser } from '../parsers/on-off-parser.js'; export type SwitchMode = 'stateful' | 'momentary'; export interface SwitchOrchestratorConfig { readonly runner: CommandRunner; readonly clock: Clock; readonly logger: Logger; readonly onStateChange: (on: boolean) => void; readonly onCommand: CommandSpec; readonly offCommand?: CommandSpec | undefined; readonly mode: SwitchMode; readonly autoResetMs?: number | undefined; readonly stateCommand?: CommandSpec | undefined; readonly stateParser?: OnOffParser | undefined; readonly statePollIntervalMs?: number | undefined; } export declare class SwitchOrchestrator { private readonly cfg; private state; private autoResetHandle; private pollHandle; private stopped; private pollInFlight; private readonly polling; constructor(cfg: SwitchOrchestratorConfig); setInitialState(on: boolean): void; isOn(): boolean; start(): void; stop(): void; setOn(on: boolean): Promise; private runOn; private runOff; private updateState; private scheduleAutoReset; private scheduleNextPoll; private pollOnce; private logCommandFailure; }