Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface WAKStorage

Hierarchy

Index

Properties

sessionStorage

sessionStorage: LockableKeyValueStorage

References the HTTP session storage of the application.

Methods

getStorage

  • Get or create a storage. This storage is shared between all your application.

    // First call creates the storage
    var myStorage = getStorage( 'mySuperHeroes' );
    myStorage.squadOne = ['Batman', 'Spiderman', 'Superman'];
    
    // Second call retrieves the storage even in another JS contexts.
    var myStorage = getStorage( 'mySuperHeroes' );
    // myStorage.squadOne returns ['Batman', 'Spiderman', 'Superman']
    
    // The storage object can be manipulate as a JS object.
    myStorage = { a:1,b:2,c:[1,2,3],d:{a:1} };
    myStorage.a++;
    myStorage.d.a++;

    Parameters

    • storageId: String

    Returns LockableKeyValueStorage

removeStorage

  • removeStorage(storageId: String): void
  • Remove a given storage.

    removeStorage( 'myCustomStorage' );

    Parameters

    • storageId: String

    Returns void