The Flash Player 11/AIR 3.0 (Serrano) release fulfills a long-standing developer request by introducing a native ActionScript JSON API. With this API, you can import and export objects using JSON encoding. Native JSON functionality correlates closely with the ECMA-262 (5.1 Edition) specification for JSON. Because of this, its syntax is somewhat different from the third-party as3corelib JSON library. You can find out more about these differences in community member Todd Anderson’s blog posting at the Infrared5 company blog.
The API itself consists of a top-level class named JSON. This class provides two methods:
stringify() for encoding, and
parse() for decoding JSON strings. The JSON feature also supports
toJSON() member functions in any class. Visit the official documentation at these locations:
ActionScript 3.0 Reference
ActionScript 3.0 Developer’s Guide
With the announcement of AIR 3 and its new native extension feature, detailed documentation about using Native Extensions for Adobe AIR is available now at:
Developing native extensions for Adobe AIR
– Overview and conceptual information
– How to use the C and Java native extension APIs, plus reference pages
– How to package your native extension using ADT
– Details on the Extension Descriptor file
– Information on using Android shared libraries, and using resources on Android and iOS
If you are using a native extension in your AIR application, see:
Using native extensions in AIR applications
For lots of examples and tutorials, see this Adobe Developer Connection page:
Over the past year we’ve been out in the community listening to issues and gathering content. The results of our labors have been links and code samples added to our help pages. While we feel this makes our content more dynamic, it doesn’t do much unless you know it there. So, in an effort to get more eyes on all this great community content, we’re spicing up our pages in a couple of ways:
In the spirit of giving credit where credit is due, here’s a list of some of authors we’ve highlighted so far:
If you have a great tutorials, videos or code sample you want to share, send it along. We’d love to add it to our content so everyone can benefit from your expertise.
Todd Anderson just posted “iBattery”, a great example of a native extension for Adobe AIR on his blog.
His iBattery extension allows an AIR application to get the status of the battery of an iOS device — from ActionScript. Todd also gives a nice tutorial highlighting some of the details that go into creating a native extension.
You can see more examples of native extensions at the Adobe Developer Connection page http://www.adobe.com/devnet/air/native-extensions-for-air.html
Looking for some examples of native extensions for Adobe AIR?
Please see Native extensions for Adobe AIR on the Adobe Developer Connection.
This page lists three sample extensions developed by Adobe to help you learn how to create your own extensions. With native extensions, an AIR application developer, using ActionScript, can take advantage of platform-specific and device-specific native capabilities.
The examples include:
- Vibration — From ActionScript, an AIR app can make an iOS or Android device vibrate.
- Gyroscope — From ActionScript, an AIR app can access the gyroscope data of an iOS or Android device.
- NetworkInfo — From ActionScript, an AIR app can get information about the network interfaces of an iOS device
Obviously, “from ActionScript” is the key. The extension’s ActionScript code interfaces with the extension’s native code, so that the AIR app developer only has to use ActionScript.
The ADC page also includes a link to a great example by Sean Fujiwara. His example uses .NET to efficiently transcode BitmapData objects into .bmp, .jpg, and .png formats. We hope to add more examples from the community soon.
Flash Media Server 4.5 is out the door! Download the development version of the server and check out how cool it is to stream on-demand and live video to media players running in Flash/AIR and iOS devices.
After you download the development server, here are some tutorials to get you started:
For detailed information about HTTP streaming to Flash and iOS, see Configure HTTP Dynamic Streaming and HTTP Live Streaming.
Other new features in Flash Media Server 4.5:
Enjoy, and please let me know if you have any questions.
The Adobe AIR 3 Release Candidate is available, and includes this new feature: Native extensions for Adobe AIR.
Until now, native extensions were available on AIR for TV, but not for AIR on desktop or mobile devices. Now you can create an ActionScript library that can execute native code on all these devices. This means an AIR application developer, using ActionScript, can take advantage of platform-specific and device-specific native capabilities.
We’ll blog here about documentation and examples as they become available. In the meantime, you can read more about it in this Adobe Developer Connection article: Extending Adobe AIR.
And get the AIR 3 Release Candidate download to get started.
Got a tasty tip or technique to offer to the Flash Platform developer community? Want a shot at winning a Samsung 10.1 tablet? If so, head on over to the Adobe Developer Center and learn more about the Adobe Cookbook recipe request challenge: http://adobe.ly/ot8Eoy. Everyone who responds to the challenge by contributing a cookbook recipe gets an Adobe Developer Connection T-shirt, plus a chance to win the tablet. Good luck!
You can now develop AIR 2.5.1 for TV apps for Samsung Smart TVs.
Register at the Samsung D Forum to learn how to package AIR apps for Samsung Smart TVs.
Read this document: AIR for TV Application Guide for Samsung TVs. You will need to login to the Samsung D Forum to read the document, but you can quickly get a login id by following the instructions on the Samsung D Forum page.
You can learn more general information for developing AIR for TV apps at Developing AIR applications for television devices.
More information like samples, tutorials, and articles are at Flash Platform for TV.