Adobe AIR enables applications to move beyond the browser and interact with many aspects of the end user’s native operating system. One of the main benefits of developing applications for the Adobe AIR runtime is the absence of some of the security sandbox restrictions that are normally found in the browser-based Flash Player.
AIR applications are installed on the local computer with permissions to access and interact with the operating system: they can interact with the filesystem, open files with default applications, and establish connections with XML Sockets.
As Rob Christensen, senior product manager of Adobe AIR, wrote, “as the definition of AIR 2 evolved, it became clear that Adobe would focus our efforts on the following themes: providing deeper integration with the operating system, making developers more productive, and improving performance.” (His “Introducing Adobe AIR 2” article is available at http://www.adobe.com/devnet/logged_in/rchristensen_air_2.html.)
This chapter focuses on the key areas that have been improved in and added to the new version of AIR and how you can leverage them to make your AIR applications work in close contact with the operating system. Specifically, the solutions presented within this chapter will show you how to do all of the following:
Read, write, move, and delete files. AIR 1 and 1.5 already provided a very rich set of API files for working with the filesystem, but AIR 2 increases the API ...