SharedObjectUtils
| Kind of class: | public class |
|---|---|
| Package: | com.bourre.utils |
| Inherits from: | none |
| Version: | 1.0 |
| Author: | Francis Bourre, Cédric Néhémie |
| Classpath: | com.bourre.utils.SharedObjectUtils |
| File last modified: | Monday, 24 November 2008, 11:36:51 |
The original
to save data on the local machine.
SharedObjectUtils class provide simple methods to save data on the local machine.
The AS3 version don't handle remote SharedObject. It's not in its main goal.
Summary
Constructor
Class methods
- loadLocal (sCookieName:String, sObjectName:String) : *
- Get a value stored in a local SharedObject.
- saveLocal (sCookieName:String, sObjectName:String, refValue:*) : Boolean
- Save a data in a local SharedObject.
- clearLocal (sCookieName:String) : Boolean
- Clear all values stored in a local SharedObject.
Constructor
Class methods
clearLocal
public static function clearLocal (
sCookieName:String) : Boolean
Clear all values stored in a local SharedObject.
If an error occurs the function die silently and return false.
Parameters:
sCookieName:
Name of the cookie.
Returns:
-
trueif the data have been cleared.
loadLocal
public static function loadLocal (
sCookieName:String,
sObjectName:String) : *
Get a value stored in a local SharedObject.
If an error occurs the function return a null value.
Parameters:
sCookieName:
Name of the cookie.
sObjectName:
Field to retreive.
Returns:
- The value stored in the field or
null.
saveLocal
public static function saveLocal (
sCookieName:String,
sObjectName:String,
refValue:*) : Boolean
Save a data in a local SharedObject.
If an error occurs the function die silently and no value is saved.
Parameters:
sCookieName:
Name of the cookie.
sObjectName:
Field to retreive.
refValue :
Value to save.
Returns:
-
trueif the data have been saved.