Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

7. Data Transfer Additions > Native JSON (JavaScript Object Notation) Support

Native JSON (JavaScript Object Notation) Support

JavaScript Object Notation (JSON) is a hugely popular way of transporting structured data sets into and out of applications that run within AIR applications. Ever since ActionScript 3.0 was introduced, there have been third-party support libraries which allowed developers to use JSON in their projects quite easily; however, this is costly in terms of performance, since it was never a core function of AIR itself.

Note

JSON is a top level class, similar to the XML or Array classes present in ActionScript. As such, they do not need to be imported in order to be used within an application.

The following JSON object describes a person through a series of name value pairs. Notice that objects can be nested and that this syntax can even include array structures. It is incredibly flexible.


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial