Class Index | File Index

Classes


Class R.storage.CookieStorage


Extends R.storage.AbstractStorage.
R.storage.CookieStorage is used to maintain data in a cookie using a JSON object. If cookies are not supported, the methods will have no effect.
Defined in: cookiestorage.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
R.storage.CookieStorage(name, options)
This class of storage is used to persist data in a cookie.
Method Summary
Method Attributes Method Name and Description
 
Clear all of the data stored in the cookie.
 
Dispose of the cookie (remove it from the user's browser).
 
Get the class name of this object
 
Initialize the storage object to the document.cookie object
 
load(key)
Get the value associated with the key from cookie storage.
 
Release the object back into the object pool.
 
save(key, value)
Save a value to cookie storage.
Methods borrowed from class R.storage.AbstractStorage:
destroy, flush, getStorageObject, loadData, saveData, setStorageObject
Methods borrowed from class R.engine.PooledObject:
clearObjectDataModel, getId, getName, getObjectDataModel, getProperties, isDestroyed, setName, setObjectDataModel, toString, toXML
Class Detail
R.storage.CookieStorage(name, options)
This class of storage is used to persist data in a cookie.
Parameters:
name
{String} The name of the cookie
options
{Object} An object which contains any of the following: path, domain, secure (boolean), and expires (number). Any of the values can be left off, in which case defaults will be used.
Method Detail
clear()
Clear all of the data stored in the cookie.

dispose()
Dispose of the cookie (remove it from the user's browser).

{String} getClassName()
Get the class name of this object
Returns:
{String} "R.storage.CookieStorage"

{Object} initStorageObject()
Initialize the storage object to the document.cookie object
Returns:
{Object} The localStorage object

{Object} load(key)
Get the value associated with the key from cookie storage.
Parameters:
key
{String} The key to retrieve data for
Returns:
{Object} The value that was stored with the key, or null

release()
Release the object back into the object pool.

save(key, value)
Save a value to cookie storage.
Parameters:
key
{String} The key to store the data with
value
{Object} The value to store with the key

Documentation generated by JsDoc Toolkit 2.4.0 on Mon Mar 18 2013 16:09:21 GMT-0400 (EDT)