45 lines
1.2 KiB
TypeScript
45 lines
1.2 KiB
TypeScript
import { Observable } from 'rxjs';
|
|
|
|
import { WindowState } from '../types/window-state.type';
|
|
import { WindowIdle } from '../types/window-idle.type';
|
|
import { NotificationRequest } from '../models/notification';
|
|
import { TranslateLoader } from '@ngx-translate/core';
|
|
import { StatusCode } from '@ucap-webmessenger/core';
|
|
|
|
export abstract class NativeService {
|
|
abstract postAppInit(): void;
|
|
|
|
abstract logout(): Observable<void>;
|
|
abstract changeStatus(): Observable<StatusCode>;
|
|
abstract showSetting(): Observable<void>;
|
|
|
|
abstract notify(noti: NotificationRequest): void;
|
|
abstract closeAllNotify(): void;
|
|
|
|
abstract checkForUpdates(): Promise<boolean>;
|
|
|
|
abstract showImageViewer(): void;
|
|
|
|
abstract saveFile(
|
|
buffer: Buffer,
|
|
fileName: string,
|
|
mimeType: string,
|
|
path?: string
|
|
): Promise<string>;
|
|
abstract readFile(path: string): Promise<Buffer>;
|
|
|
|
abstract windowStateChanged(): Observable<WindowState>;
|
|
abstract windowClose(): void;
|
|
abstract windowMinimize(): void;
|
|
abstract windowMaximize(): void;
|
|
|
|
abstract idleStateChanged(): Observable<WindowIdle>;
|
|
|
|
abstract chatOpenRoom(): Observable<string>;
|
|
|
|
abstract getTranslateLoader(
|
|
prefix?: string,
|
|
suffix?: string
|
|
): TranslateLoader;
|
|
}
|