@ux-aspects/ux-aspects
Version:
Open source user interface framework for building modern, responsive, mobile big data applications
31 lines (30 loc) • 993 B
TypeScript
import * as i0 from "@angular/core";
export declare class PersistentDataService {
/**
* Save the item in some form of persistent storage
*/
setItem(key: string, value: string, type?: PersistentDataStorageType): void;
/**
* Get a stored value from persistent storage
*/
getItem(key: string, type?: PersistentDataStorageType): string;
/**
* Remove a stored value from persistent storage
*/
removeItem(key: string, type?: PersistentDataStorageType): void;
/**
* Remove a stored value from persistent storage
*/
clear(type?: PersistentDataStorageType): void;
/**
* Return the appropriate adapter based on the type requested
*/
private getAdapter;
static ɵfac: i0.ɵɵFactoryDeclaration<PersistentDataService, never>;
static ɵprov: i0.ɵɵInjectableDeclaration<PersistentDataService>;
}
export declare enum PersistentDataStorageType {
LocalStorage = 0,
Cookie = 1,
SessionStorage = 2
}