@alfresco/adf-core
Version:
24 lines (23 loc) • 1.14 kB
TypeScript
import { Observable } from 'rxjs';
import { FlagChangeset, IFeaturesService, FlagSet, IWritableFeaturesService, WritableFlagChangeset, WritableFeaturesServiceConfig } from '../interfaces/features.interface';
import * as i0 from "@angular/core";
export declare class StorageFeaturesService implements IFeaturesService, IWritableFeaturesService {
private config?;
private currentFlagState;
private readonly flags;
private readonly flags$;
private readonly initSubject;
constructor(config?: WritableFeaturesServiceConfig);
get storageKey(): string;
init(): Observable<WritableFlagChangeset>;
isOn$(key: string): Observable<boolean>;
isOff$(key: string): Observable<boolean>;
getFlags$(): Observable<WritableFlagChangeset>;
setFlag(key: string, value: any): void;
removeFlag(key: string): void;
resetFlags(flags: FlagSet): void;
mergeFlags(flags: FlagChangeset): void;
private waitForInitializationToFinish;
static ɵfac: i0.ɵɵFactoryDeclaration<StorageFeaturesService, [{ optional: true; }]>;
static ɵprov: i0.ɵɵInjectableDeclaration<StorageFeaturesService>;
}