Adobe MAX 2009 is the largest conference where Adobe presented many interesting projects and announced the release of the CS 5 line of its products next year (and there are a lot of interesting things already now, for example, Flash CS 5 promise an
available beta by the end of the year ). But for web developers, the most anticipated is a fairly small project (compared to others) - Adobe AIR 2.0. The current version 1.5.x has a strong support from the industry and developers, including because it uses all the familiar technologies for development - JavaScript / HTML and Flash. AIR applications are produced by many companies, including industry giants like eBay, NASDAQ, FedEx, Fox media giant and others, Adobe itself has created several multimedia projects to distribute its platform.
But on the horizon, there is already news about the next generation of AIR, which should not just further strengthen its position in the field of platforms for web applications, but even, without exaggeration, simply remove all other competing platforms. What awaits us in AIR 2.0?
I have repeatedly stated that AIR is still the best platform for RAI applications, without any deviations from the word "applications". Many companies, including industry giants like eBay, NASDAQ, FedEx, Fox media and others, produce projects for AIR, Adobe itself has created several multimedia projects to distribute its platform.
In this review, I described several competing platform products for the RIA, but even the most
powerful Appcelerator Titanium still cannot boast of all AIR 2 chips, although, no doubt, the first and real candidate for competition is, especially in version 0.7, where it has already appeared PHP support as a scripting language.
')
And now about the main thing ...

- Ability to launch external applications - yes, now you can initiate the opening of applications from AIR, for example, if you work with Word or Excel documents, you can give the user the ability to open the file in his native program directly from the application, previously it was available only for PDF- files (as I understand it, just because Flash has learned to render PDF).
- If more, then new classes are responsible for this functionality: flash.desktop.NativeProcess, which allows working with the command interface, intercepting and processing standard input / output streams and errors, flash.desktop.NativeProcessStartupInfo to get information about processes, flash.events.NativeProcessExitEvent - handle the completion event of a thread Important note - this functionality is available only for applications in the form of native installers, for air packages that can be installed from a web page, they are not available (apparently for security reasons).
- For the ability to open files in native applications, the openWithDefaultApplication method is responsible, through which you can open the file in the associated application, or run it if it is an application (executable file).
- Native installation packages for the application. If earlier your program was packaged into a platform-independent * .air format (very similar to jar), then now you can create native applications for each platform (the question remains open - whether it will be possible to create an independent distribution when AIR is included in the package) . Of course, the option with the air package will also remain. In this regard, Adobe as a catch-up, because the very same Titanium initially possessed these capabilities (there the entire execution environment comes immediately with the program and is individual for each application, unlike the one shared in AIR).
- Advanced file management and desktop integration - FilePromise, URLFilePromise, which allows you to work with files and transfer them between the application and the OS (in fact, the ability to specify the URL or file as trusted and process in the application, then transfer the OS).
- Extended work with sockets. This is probably the most important and expected innovation - the creation of server sockets, which Flash couldn’t do before, but AIR can (in the very same Titanium it has been around for a long time and, in my opinion, often the most significant advantage of this platform). The class flash.net.ServerSocket is intended for this.
- IPv6 support. While not very relevant, but if your application should work within its own network or intranet, it can be useful.
- UDP protocol support - now there is a support, in addition to TCP, also a UDP protocol, which will allow you to work as quickly as possible with services for which minimal delays are important, the rest can be neglected, but it is not yet known whether UDP will be supported in server sockets. The flash.net.DatagramSocket class is responsible for UDP sockets.
- Network information. An application using the flash.net.NetworkInfo class can get much more information about the network environment. While true, information is limited to the list of available network interfaces and IP address information.
- Work with DNS-records and servers. Allows the app to retrieve all information about an arbitrary domain and communicate directly with the DNS server. Apparently, we should expect special applications for SEO, as well as platforms for cybersquatters.
- Applications will now be provided with support for special screens and / or programs for people with disabilities ( Screen Reader ). While this functionality is available only in Windows and includes working with dialog boxes, as well as special classes for Flex components.
- Direct access to the microphone and audio stream. This opportunity was expected by very many! Now you can record sound from a microphone without the need for a remote server, getting access to raw stream data in the form of PCM ByteArray. Data can be saved to a wav file and played from the application. In principle, direct encoding to another format is also possible.
- Embedded DBMS receives enhanced support for transactions and savepoints. To do this, the new functions savepoints (), setSavepoint (), releaseSavepoint () and rollbackToSavepoint () are introduced.
- Advanced features for working with printing systems. Now you can individually specify the print mode for each element (or page), in particular, set the output mode (vector or raster), if it is supported by the OS and the driver. Read more about the print subsystem in ActionScript 3 here .
- Idle timeout support - as far as I understand, it is possible to detect the user's mode of operation and determine whether it is currently working with the application or not, for example, to switch to the background.
- The maximum size of the application window is now expanded to 4095x4095 pixels, which allows you to run AIR applications on large screens and use the entire available area. Also added support for touch screens and multi-touch.
- Working with storage systems - an application through new classes flash.filesystem.StorageVolume and flash.filesystem.StorageVolumeInfo can receive complete information about all storage systems, disks, logical partitions, determine the ability to write to partitions, detect removable disks and flash drives.
- New features for global error trapping, essentially a try / catch block for the entire application together.
- Profiling and debugger for javascript code.
- Profiles for an application - you can selectively create profiles for various uses of the application, including or disabling those or other features. The following profiles are now available: desktop for regular applications, NativeDesktop for applications with a native installer, mobile and extenden mobile for mobile applications.
- Mobile application support. Yes Yes Yes! You can create mobile applications, including for the iPhone - and these will be native applications for the Apple platform (while there are difficulties with Flash on the iPhone, Adobe simply generates native code for the iPhone).
- The updated Webkit rendering engine (the same as in Safari 4 beta) now allows you to:
- use the fastest JavaScript engine - SquirrelFish Extreme (with many optimizations, including polymorphic caching and lightweight JIT compiler)
- CSS Transformations (CSS Transformations)
- CSS Transitions
- CSS animation (CSS Animations)
- gradients (CSS Gradients)
- Quick Selector API for accessing DOM nodes (Webkit CSS selectors)
- In Flash / Flex, parts of the application can now be freely created and rendered via the embedded Webkit HTML, JS and even PDF documents, working with the structure of the document in the same way as with AS objects.
Here, perhaps that's all. In my opinion, the changes are excellent and will significantly expand the scope of AIR and the range of applications. From what is relevant for me, of course, is working with the network (server sockets, UDP protocol), the ability to create native applications with the installer, improvements in the Webkit engine, and especially in the JavaScript engine. It remains only to wish something serious about working with 3D graphics, for example, WebGL and the best support for acceleration. Also, I'm not sure about the possibilities of working with SSL and cryptography in general. I would also like more built-in libraries that would be available not only in Flash, but also in the JavaScript API. And so - just fine! We wait!
PS Link to the recording of a presentation on AIR 2.0 .