UNPKG

@sussudio/platform

Version:

Internal APIs for VS Code's service injection the base services.

73 lines (71 loc) 3.1 kB
/*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ import { Event } from '@sussudio/base/common/event.mjs'; import { Disposable } from '@sussudio/base/common/lifecycle.mjs'; import { IProductService } from '../../product/common/productService.mjs'; import { IStorageService } from '../../storage/common/storage.mjs'; import { ITelemetryService } from '../../telemetry/common/telemetry.mjs'; import { IUserDataAutoSyncService, IUserDataSyncLogService, IUserDataSyncEnablementService, IUserDataSyncService, IUserDataSyncStoreManagementService, IUserDataSyncStoreService, UserDataSyncError, } from './userDataSync.mjs'; import { IUserDataSyncAccountService } from './userDataSyncAccount.mjs'; import { IUserDataSyncMachinesService } from './userDataSyncMachines.mjs'; export declare class UserDataAutoSyncService extends Disposable implements IUserDataAutoSyncService { private readonly userDataSyncStoreManagementService; private readonly userDataSyncStoreService; private readonly userDataSyncEnablementService; private readonly userDataSyncService; private readonly logService; private readonly userDataSyncAccountService; private readonly telemetryService; private readonly userDataSyncMachinesService; private readonly storageService; _serviceBrand: any; private readonly autoSync; private successiveFailures; private lastSyncTriggerTime; private readonly syncTriggerDelayer; private suspendUntilRestart; private readonly _onError; readonly onError: Event<UserDataSyncError>; private lastSyncUrl; private get syncUrl(); private set syncUrl(value); private previousProductQuality; private get productQuality(); private set productQuality(value); constructor( productService: IProductService, userDataSyncStoreManagementService: IUserDataSyncStoreManagementService, userDataSyncStoreService: IUserDataSyncStoreService, userDataSyncEnablementService: IUserDataSyncEnablementService, userDataSyncService: IUserDataSyncService, logService: IUserDataSyncLogService, userDataSyncAccountService: IUserDataSyncAccountService, telemetryService: ITelemetryService, userDataSyncMachinesService: IUserDataSyncMachinesService, storageService: IStorageService, ); private updateAutoSync; protected startAutoSync(): boolean; private isAutoSyncEnabled; turnOn(): Promise<void>; turnOff(everywhere: boolean, softTurnOffOnError?: boolean, donotRemoveMachine?: boolean): Promise<void>; private updateEnablement; private hasProductQualityChanged; private onDidFinishSync; private disableMachineEventually; private hasToDisableMachineEventually; private stopDisableMachineEventually; private sources; triggerSync(sources: string[], skipIfSyncedRecently: boolean, disableCache: boolean): Promise<void>; protected getSyncTriggerDelayTime(): number; }