import { LoggerInterface } from '@standardnotes/utils'; import { ClientDisplayableError } from '@standardnotes/responses'; import { RoleName, Uuid } from '@standardnotes/domain-core'; import { PureCryptoInterface } from '@standardnotes/sncrypto-common'; import { NativeFeatureIdentifier } from '@standardnotes/features'; import { SNFeatureRepo, DecryptedItemInterface } from '@standardnotes/models'; import { AbstractService, AlertService, FeaturesClientInterface, FeaturesEvent, FeatureStatus, InternalEventBusInterface, InternalEventHandlerInterface, InternalEventInterface, OfflineSubscriptionEntitlements, SetOfflineFeaturesFunctionResponse, MutatorClientInterface, StorageServiceInterface, LegacyApiServiceInterface, ItemManagerInterface, SyncServiceInterface, SessionsClientInterface, UserServiceInterface, SubscriptionManagerInterface, IsApplicationUsingThirdPartyHost, WebSocketsService } from '@standardnotes/services'; import { SettingsClientInterface } from '../Settings/SettingsClientInterface'; export declare class FeaturesService extends AbstractService implements FeaturesClientInterface, InternalEventHandlerInterface { private storage; private items; private mutator; private subscriptions; private api; private settings; private user; private sync; private alerts; private sessions; private crypto; private logger; private isApplicationUsingThirdPartyHostUseCase; protected internalEventBus: InternalEventBusInterface; private onlineRoles; private offlineRoles; private enabledExperimentalFeatures; private getFeatureStatusUseCase; private readonly PROD_OFFLINE_FEATURES_URL; constructor(storage: StorageServiceInterface, items: ItemManagerInterface, mutator: MutatorClientInterface, subscriptions: SubscriptionManagerInterface, api: LegacyApiServiceInterface, sockets: WebSocketsService, settings: SettingsClientInterface, user: UserServiceInterface, sync: SyncServiceInterface, alerts: AlertService, sessions: SessionsClientInterface, crypto: PureCryptoInterface, logger: LoggerInterface, isApplicationUsingThirdPartyHostUseCase: IsApplicationUsingThirdPartyHost, internalEventBus: InternalEventBusInterface); initializeFromDisk(): void; handleEvent(event: InternalEventInterface): Promise; enableExperimentalFeature(identifier: string): void; disableExperimentalFeature(identifier: string): void; toggleExperimentalFeature(identifier: string): void; getExperimentalFeatures(): string[]; isExperimentalFeature(featureId: string): boolean; getEnabledExperimentalFeatures(): string[]; isExperimentalFeatureEnabled(featureId: string): boolean; setOfflineFeaturesCode(code: string): Promise; private getOfflineRepo; hasOfflineRepo(): boolean; deleteOfflineFeatureRepo(): Promise; parseOfflineEntitlementsCode(code: string): OfflineSubscriptionEntitlements | ClientDisplayableError; private downloadOfflineRoles; migrateFeatureRepoToUserSetting(featureRepos?: SNFeatureRepo[]): Promise; migrateFeatureRepoToOfflineEntitlements(featureRepos?: SNFeatureRepo[]): Promise; hasPaidAnyPartyOnlineOrOfflineSubscription(): boolean; hasFirstPartyOnlineSubscription(): boolean; hasFirstPartyOfflineSubscription(): boolean; updateOnlineRolesWithNewValues(roles: string[]): Promise; setOnlineRoles(roles: string[]): void; setOfflineRoles(roles: string[]): void; isThirdPartyFeature(identifier: string): boolean; private rolesIncludePaidSubscription; onlineRolesIncludePaidSubscription(): boolean; rolesBySorting(roles: string[]): string[]; hasRole(roleName: RoleName): boolean; hasMinimumRole(role: string): boolean; getFeatureStatus(featureId: NativeFeatureIdentifier | Uuid, options?: { inContextOfItem?: DecryptedItemInterface; }): FeatureStatus; deinit(): void; }