Adobe Integrated Runtime (AIR) for JavaScript Developers Pocket Reference

(nextflipdebug5) #1

30 | Chapter 2: Getting Started with AIR Development


Open AIRHelloWorld.xml and type in the following text:


<?xml version="1.0" encoding="UTF-8"?>
<application xmlns="http://ns.adobe.com/air/application/1.0.M4"
appId="com.oreilly.AIRHelloWorld"
version="1.0">

<name>AIRHelloWorld</name>
<title>AIRHelloWorld Installer</title>
<description>Simple Hello World Example
using HTML</description>
<copyright></copyright>

<rootContent systemChrome="standard"
transparent="false" visible="true">
ApolloHelloWorld.html</rootContent>

</application>

The content should be pretty self-explanatory, but let’s go
through it line by line to understand what is going on.


<application xmlns="http://ns.adobe.com/air/application/1.0.M4"
appId="com.oreilly."
version="1.0">

There are two items worth pointing our here. First, the
namespace definition:


xmlns="http://ns.adobe.com/air/application/1.0.M4"

This specifies the build of Adobe AIR that the application
targets. In this case, it specifies 1.0.M4, which is the public
Beta.


TheappIdproperty is important, and specifies a unique ID
for the AIR application. Adobe AIR uses this ID to deter-
mine one application from another.


As you can see, it uses the reverse domain format, which you
may be familiar with from some programming languages
such as Java, ActionScript, and some JavaScript frameworks.
You can create your own ID using your domain name and
application name.

Free download pdf