
Server-Side Communication ActionScript 11
Description
Method; accepts the connection call from a client to the server. The application.onConnect
event handler is invoked on the server side to notify a script when
NetConnection.connect is
called from the client side. You can use the application.acceptConnection method inside an
application.onConnect event handler to accept a connection from a client. You can use the
application.acceptConnection method outside an application.onConnect event handler
to accept a client connection that had been placed in a pending state (for example, to verify a user
name and password).
Example
The following example uses the application.acceptConnection method to accept the
connection from
client1:
application.onConnect = function (client1){
// insert code here
application.acceptConnection(client1);
client1.call("welcome");
};
See also
Application.onConnect, Application.rejectConnection
Application.clearSharedObjects
Availability
Flash Communication Server MX.
Usage
application.clearSharedObjects(soPath);
Parameters
soPath A string that indicates the URI of a shared object.
Returns
Nothing.
Description
Method; removes persistent shared objects specified by the soPath parameter and clears all
properties from active shared objects (both persistent and nonpersistent). You can use the
SharedObject object to create shared objects in a Flash Communication Server application
instance. The Flash Communication Server stores persistent shared objects for each application.
You can use
application.clearSharedObjects to handle one shared object at a time, so you
must specify the name of the shared object. You can also use
application.clearStreams to
remove all the recorded streams based on a stream path.
The
soPath parameter specifies the name of a shared object, which can include a slash (/) as a
delimiter between directories in the path. The last element in the path can contain wildcard
patterns (for example, a question mark [?] and an asterisk [*]) or a shared object name. The
application.clearSharedObjects method traverses the shared object hierarchy along the
specified path and clears all the shared objects. Specifying the a slash clears all the shared objects
associated with an application instance.
Commenti su questo manuale