• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

Application Instances

Like any normal ActionScript object, applications have to be instanced before they can be used. This is an important concept when using the Flash Communication Server. In Chapter 10, “STEP 10: Lobby Applications,” you saw instancing in action, with the RoomList component. SSAS within the main.asc file is compiled each time a new instance of the application is run. You create instances using the NetConnection.connect ActionScript in either the Flash player or SSAS. As you saw earlier, you can also manually create an instance using the App Inspector. Each Application instance operates within its own context. Users connected to instances of an application cannot access other instances without closing the current connection and opening another connection (see Figure 11.1). This is an extremely important security feature with the Flash Communication Server.

Figure 11.1. The Application instance makes a copy of the Application object. Instances have no relationship with each other without a NetConnection bridge.



PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint