618 Chapter 12: ActionScript Dictionary
The following list summarizes how the user’s disk space choices interact with shared objects:
• If the user selects Never, objects are never saved locally, and all SharedObject.flush()
commands issued for the object return
false.
• If the user selects Unlimited (moves the slider all the way to the right), objects are saved locally
up to available disk space.
• If the user selects None (moves the slider all the way to the left), all SharedObject.flush()
commands issued for the object return
"pending" and cause the player to ask the user if
additional disk space can be allotted to make room for the object, as explained above.
• If the user selects 10 KB, 100 KB, 1 MB, or 10 MB, objects are saved locally and
SharedObject.flush() returns true if the object fits within the specified amount of space. If
more space is needed,
SharedObject.flush() returns "pending", and the player asks the
user if additional disk space can be allotted to make room for the object, as explained above.
Additionally, if the user selects a value that is less than the amount of disk space currently being
used for locally persistent data, the player warns the user that any locally saved shared objects will
be deleted.
Note: There is no size limit in Flash Player that runs from the authoring environment.
Method summary for the SharedObject class
Property summary for the SharedObject class
Event handler summary for the SharedObject class
Method Description
SharedObject.clear() Purges all of the data from the shared object and deletes the
shared object from the disk.
SharedObject.flush() Immediately writes a locally persistent shared object to a local file.
SharedObject.getLocal() Returns a reference to a locally persistent shared object that is
available only to the current client.
SharedObject.getSize() Gets the current size of the shared object, in bytes.
Property (read-only) Description
SharedObject.data The collection of attributes assigned to the data property of the
object; these attributes can be shared and/or stored.
Event handler Description
SharedObject.onStatus Invoked every time an error, warning, or informational note is
posted for a shared object.