MACROMEDIA FLASH MEDIA SERVER 2-CLIENT-SIDE ACTIONSCRIPT LANGUAGE REFERENCE FOR FLASH MEDIA SERVER 2 Instrukcja Użytkownika Strona 135

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 172
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 134
132
SERVER-SIDE ACTIONSCRIPT LANGUAGE REFERENCE FOR ADOBE MEDIA SERVER 5.0.1
Server-Side ActionScript Language Reference
Last updated 7/2/2013
Server-side shared objects can be owned by the current application instance or by another application instance.
The other application instance can be on the same server or on a different server. References to shared objects
that are owned by a different application instance are called proxied shared objects.
If you write a server-side script that modifies multiple properties, you can prevent other clients from modifying the
object during the update by calling the
SharedObject.lock() method before updating the object. Then you can
call
SharedObject.unlock() to commit the changes and allow other changes to be made. Call
SharedObject.mark() to deliver change events in groups within the lock() and unlock() methods.
When you get a reference to a proxied shared object, any changes made to the object are sent to the instance that
owns the object. The success or failure of any changes is sent by using the
SharedObject.onSync() event handler,
if it is defined.
The SharedObject.lock() and SharedObject.unlock() methods cannot lock or unlock proxied shared
objects.
Availability
Flash Communication Server 1
Property summary
Method summary
Property Description
SharedObject.autoCommit A boolean value indicating whether the server periodically stores all persistent shared objects (true)
or not (
false).
SharedObject.isDirty Read-only; a boolean value indicating whether the persistent shared object has been modified since
the last time it was stored (
true) or not (false).
SharedObject.name Read-only; the name of a shared object.
SharedObject.resyncDepth An integer that indicates when the deleted values of a shared object should be permanently deleted.
SharedObject.version Read-only; the current version number of a shared object.
Method Description
SharedObject.clear() Deletes all the properties of a single shared object and sends a clear event to all clients that
subscribe to a persistent shared object.
SharedObject.close() Detaches a reference from a shared object.
SharedObject.commit() Static; stores either a specific persistent shared object instance or all persistent shared object
instances with an
isDirty property whose value is true.
SharedObject.flush() Saves the current state of a persistent shared object.
SharedObject.get() Static; creates a shared object or returns a reference to an existing shared object.
SharedObject.getProperty() Retrieves the value of a named property in a shared object.
SharedObject.getPropertyNames() Enumerates all the property names for a given shared object.
SharedObject.lock() Locks a shared object.
SharedObject.mark() Delivers all change events to a subscribing client as a single message.
SharedObject.purge() Causes the server to remove all deleted properties that are older than the specified version.
SharedObject.send() Executes a method in a client-side script.
Przeglądanie stron 134
1 2 ... 130 131 132 133 134 135 136 137 138 139 140 ... 171 172

Komentarze do niniejszej Instrukcji

Brak uwag