The 'NetConnection()' Object

Flash Player 6 connects with the Flash Communication Server using the NetConnection() object. The NetConnection() object maintains persistent connection using the Real Time Messaging Protocol (RTMP). It is defined by Macromedia as "the object that manages multi-directional communication between the Flash Communication Server and Flash Remoting MX servers." Think of the NetConnection like a tunnel between the client and server. The tunnel can facilitate the transmission of multiple one-way streams or ActionScript objects coded in Action Message Format (AMF). It is the only two-way connection possible between client and server. The NetConnection() object cannot establish a connection between two Flash players; for that functionality, you can use the LocalConnection object.



    Part I: 10 Quick Steps for Getting Started