lavva.exalushome
Version:
Library implementing communication and abstraction layers for ExalusHome system
45 lines (44 loc) • 2.42 kB
TypeScript
import { ITypedEvent } from "../../TypedEvent";
import { IEvent } from "../../Event";
import { ControllerConfigurationErrorCode, IControllerConfigurationService } from "./IControllerConfigurationService";
import { Status } from '../../DataFrame';
import { ResponseResult } from "../FieldChangeResult";
export declare class ControllerConfigurationService implements IControllerConfigurationService {
private _connection;
private _session;
private _localStorage;
static readonly ServiceName: string;
private _onEnteredConfigurationEvent;
private _onExitedConfigurationEvent;
private _onConfigurationTimeCheckedEvent;
private _configurationTime;
private _appEnteredConfigurationMode;
private _didConfigurationChange;
static ConfigurationTimeRetrieved: Date | null;
private _synchronizationTaskCompletionSource;
GetServiceName(): string;
constructor();
CheckIfControllerSoftwareVersionIsEnough(requiredContainerMajor: number, requiredContainerMinor: number): boolean;
ImportControllerConfigurationAsync(file: File): Promise<Status>;
SplitStringBySize(input: string, maxSizeInBytes?: number): string[];
GetControllerSystemTimeAsync(): Promise<Date | Status>;
SetControllerSystemTimeAsync(date: Date): Promise<Status>;
StartNtpTimeSynchronizationAsync(): Promise<Status>;
FactoryResetAsync(func: (progress: number) => void): Promise<Status>;
RollbackLastUpdateAsync(func: (progress: number) => void): Promise<Status>;
RestartControllerAsync(func: (progress: number) => void): Promise<Status>;
DidCofigurationChangeAsync(): Promise<boolean>;
private GetLastKnownConfigurationChangeTime;
private SaveLastConfigurationChangeTime;
EnterConfigurationModeAsync(): Promise<void>;
ExitConfigurationModeAsync(): Promise<void>;
OnEnteredConfigurationEvent(): IEvent;
OnExitedConfigurationEvent(): IEvent;
OnConfigurationTimeCheckedEvent(): ITypedEvent<Date>;
GetLastConfigurationChangeTimeAsync(): Promise<Date>;
CheckIfConfigurationHasChangedAsync(): Promise<boolean>;
CheckIfConfigurationTimeHasChangedAsync(currentConfigurationTime: Date): Promise<boolean>;
CanExportOrImportControllerConfigurationAsync(): Promise<boolean>;
ExportControllerConfigurationAsync(): Promise<HTMLAnchorElement | ResponseResult<ControllerConfigurationErrorCode>>;
private GetCurrentTimestampedFilename;
}