Storage Class

A local disk-based cache for key value pairs for NativeApps.

note This should be used only for local caching, since its not guaranteed to exist permanently.

Methods

Name Description
constructor(id: string): Storage    
getData(key: string): Promise<undefined | StorageValue> Get the value for a key  
getKeys(): Promise<string[]> Return an array of all keys in this Storage.  
removeAll(): Promise<void> Remove all keys and their data.  
removeData(key: string): Promise<void> Remove a key and its data.  
setData(key: string, value: StorageValue): Promise<void> Set value for a key  

Properties

Name Type Description
id Readonly string    

Defined in

Last Updated: 11 June, 2024