MACROMEDIA FLASH MEDIA SERVER 2-CLIENT-SIDE ACTIONSCRIPT LANGUAGE REFERENCE FOR FLASH MEDIA SERVER 2 Manuel d'utilisateur Page 11

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 172
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 10
8
SERVER-SIDE ACTIONSCRIPT LANGUAGE REFERENCE FOR ADOBE MEDIA SERVER 5.0.1
Server-Side ActionScript Language Reference
Last updated 7/2/2013
Event handler summary
application.acceptConnection()
application.acceptConnection(clientObj)
Accepts a connection call from a client to the server.
Availability
Flash Communication Server 1
Parameters
clientObj A Client object; a client to accept.
Details
When NetConnection.connect() is called from the client side, it passes a Client object to
application.onConnect() on the server. Call application.acceptConnection() in an
application.onConnect() event handler to accept a connection from a client. When this method is called,
NetConnection.onStatus() is invoked on the client with the info.code property set to
"NetConnection.Connect.Success".
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).
When you call this method, NetConnection.onStatus() is invoked on the client with the info.code property set
to
"NetConnection.Connect.Success". For more information, see the NetStatusEvent.info property in the
ActionScript 3.0 Language and Components Reference or the
NetConnection.onStatus() entry in the Adobe Media
Server ActionScript 2.0 Language Reference.
Note: When you use version 2 components, the last line (in order of execution) of the onConnect() handler should be
either
application.acceptConnection() or application.rejectConnection() (unless you’re leaving the
application in a pending state). Also, any logic that follows
acceptConnection() or rejectConnection() must be
placed in the
application.onConnectAccept() and application.onConnectReject() handlers, or it will be
ignored.
Event handler Description
application.onAppStart() Invoked when the server loads an application instance.
application.onAppStop() Invoked when the server is about to unload an application instance.
application.onConnect() Invoked when NetConnection.connect() is called from the client.
application.onConnectAccept() Invoked when a client successfully connects to an application; for use with version 2
components only.
application.onConnectReject() Invoked when a connection is rejected in an application that contains components.
application.onDisconnect() Invoked when a client disconnects from an application.
application.onPeerLookup() Invoked when the server receives a lookup request.
application.onPublish() Invoked when a client publishes a stream to an application.
application.onStatus() Invoked when the server encounters an error while processing a message that was targeted
at this application instance.
application.onUnpublish() Invoked when a client stops publishing a stream to an application.
Vue de la page 10
1 2 ... 6 7 8 9 10 11 12 13 14 15 16 ... 171 172

Commentaires sur ces manuels

Pas de commentaire