Namespace: storage

jsxc. storage

Handle long-live data
Source:

Members

<static> PREFIX

Prefix for localstorage
Source:

Methods

<static> getItem(key, uk)

Load item from storage
Parameters:
Name Type Description
key String variablename
uk String Userkey? Should we add the bid as prefix?
Source:

<static> getPrefix(uk) → {String}

Parameters:
Name Type Description
uk type Should we generate a user prefix?
Source:
Returns:
prefix
Type
String

<static> getUserItem(key)

Get a user item from storage.
Parameters:
Name Type Description
key
Source:
Returns:
user item

<static> ink(key, uk)

Inkrements value
Parameters:
Name Type Description
key String variablename
uk String Userkey? Should we add the bid as prefix?
Source:

<static> onStorage(e)

Triggered if changes are recognized
Parameters:
Name Type Description
e event Storageevent
Properties
Name Type Description
key String Keyname which triggered event
oldValue Object Old Value for key
newValue Object New Value for key
url String
Source:

<static> removeElement(key, name, uk) → {undefined}

Remove element from array or object
Parameters:
Name Type Description
key string name of array or object
name string name of element in array or object
uk String Userkey? Should we add the bid as prefix?
Source:
Returns:
Type
undefined

<static> removeItem(key, uk)

Remove item from storage
Parameters:
Name Type Description
key String variablename
uk String Userkey? Should we add the bid as prefix?
Source:

<static> removeUserItem(key)

Remove user item from storage.
Parameters:
Name Type Description
key
Source:

<static> saveBuddy(bid, data) → {String}

Save or update buddy data.
Parameters:
Name Type Description
bid
data
Source:
Returns:
Updated or created
Type
String

<static> setItem(key, value, uk)

Save item to storage
Parameters:
Name Type Description
key String variablename
value Object value
uk String Userkey? Should we add the bid as prefix?
Source:

<static> updateItem(key, variable, value, uk)

Updates value of a variable in a saved object.
Parameters:
Name Type Argument Description
key String variablename
variable String | object variablename in object or object with variable/key pairs
value Object <optional>
value
uk String Userkey? Should we add the bid as prefix?
Source:

<static> updateUserItem(key, variable, value)

Updates value of a variable in a saved user object.
Parameters:
Name Type Argument Description
key String variablename
variable String | object variablename in object or object with variable/key pairs
value Object <optional>
value
Source: