schoolx-ota-manager
Version:
React Native library for managing OTA updates with GitLab integration
37 lines • 1.02 kB
TypeScript
import { OtaConfig, UpdateInfo, UpdateProgress } from './types';
export declare class OtaManager {
private config;
private gitlabService;
private onProgressCallback?;
constructor(config: OtaConfig);
/**
* Set progress callback
*/
onProgress(callback: (progress: UpdateProgress) => void): void;
/**
* Check for updates
*/
checkUpdate(): Promise<UpdateInfo>;
/**
* Download and install update
*/
installUpdate(): Promise<boolean>;
/**
* Check and install update automatically
*/
checkAndInstallUpdate(): Promise<boolean>;
/**
* Check for updates when app starts (called once)
*/
checkOnAppStart(): Promise<UpdateInfo | null>;
/**
* Get current installed build number
*/
getInstalledBuildNumber(): Promise<number>;
/**
* Clear installed build number (for testing)
*/
clearInstalledBuildNumber(): Promise<void>;
private notifyProgress;
}
//# sourceMappingURL=OtaManager.d.ts.map