-
-
Notifications
You must be signed in to change notification settings - Fork 16
._restore
localDataStorage._restore( keyName, [overwriteExistingKey] )
This Memory Key method effectively moves the value of keyName, a localStorage Key, into memory, creating a new Memory Key if necessary. This is the way to restore a previous backup of memory to disk.
The data type is of course respected.
This will overwrite an existing value for keyName when the optional overwriteExistingKey is true (and throw an error when it is not). If this happens, the prior value cannot be retrieved.
The operation verifies the destination Memory Key has been created. Once verified, the localStorage key is deleted.
EXAMPLE:
● localData._restore( 'key1' )
✨ The complement to this is _backup.
📝 NOTE: When a Memory Key session must resume, restore any backed up keys to memory using this method.
Array Keys:
push / pull, pullall poke contains where
Broadcasting:
broadcast
Data Transfer:
import / export
Duplicates:
countdupes, showdupes, listdupes
Internals:
cancrunch crunch / uncrunch
shufflestring / unshufflestring
Management:
keys
Memory Consumption:
Memory Quota:
showquota
Query:
haskey, hasval, hastype
setscramblekey / getscramblekey
Type Check:
isarray isbigint isboolean iscrunch
isdate isfloat isinteger isnull
Utility:
chopget copy softset rename
_set / _get _clear _key _remove
Management:
_keys
Type Check:
_isarray _isbigint _isboolean _iscrunch