Flex Code Camp 2010 (Preparation Only)
Flex Code Camp 2010 (Preparation Only)
Flex Code Camp 2010 (Preparation Only)
- /01#+)1)23'4 54"67
Preparation Guide
This document is to help you prepare your own laptop for the Flex
Boot Camp. If you run into any issues during completion of this
document, please contact dnickull@adobe.com.
Please make every effort to have your laptop prepared and
functioning before you come to the Boot Camp.
License:
Other than product images, this work is licensed under a Creative Commons Attribution 3.0 Unported License. You
may redistribute and quote from parts of this article however attribution is expected. There is no
need to seek explicit permission to reuse part of this paper or quote from it.
Table of Contents
!"#$%#&' )
*#+*%#%,-". )
8'94"')( )4( 34:2)"" ;('<# ;=> .?@?, '1 ")2#1 /A)BC 0&C D34E$7 F
8'94"')( )4( 34:2)"" !"):G HE3"(#1 F H#2) F
&'E1:#9)1# &8 @
H")I#8J /5+23'4)"7 @
A. Installing anu configuiing Auobe Flex Builuei. 9
Set up anu account with Yahoo anu uownloau the SWC file. 1u
Accessing the configuiing the YahooNaps.swc file. 12
Bownloau the ESRI AicuIS SWC libiaiy. 12
/5+23'4)"7 K 8'94"')( )4( 34:2)"" A;A0 /A)B7 '1 L;A0 /L34('9:7 .F
%**+.&-/ %' 0%1% 0&2 34
8'94"')(34MC 34:2)""34M )4( B'4N3ME134M O)P) O8Q .@
J#2234M 2G# O)P) 0;RS )4( O;T;US5AV .W
!567869'
Welcome to the Flex Coue Camp. This couise has been put togethei in hopes to
pioviue uevelopeis a boot camp to leain all the basics of Auobe Flex anu AIR
uevelopment. 0ui oveiall goal is to pioviue you with an intiouuction to AIR so you
can make youi own uecision if you want to puisue this exciting new application
uevelopment technology in the futuie. If you uo, we will be pioviuing auuitional
iefeiences wheie you can continue leaining anu become pait of the laigei
community aftei this couise is ovei.
=A05>R;XRY RG#1# 3: ) G3MG +1'<)<3"326 9# 93"" 4'2 M#2 2G1'EMG 2G# #4231#
B'E1:# (E134M 2G# 23*# )""'22#(? RG3: 3: <6 (#:3M4? RG# B'E1:# 1#N"#B2: ) <#:2
B):# :B#4)13' 9G#1#<6 #P#16'4# B'P#1: 2G# *)2#13)": ZE3B["6? L# N#"2 32 <#22#1
2' G)P# #$21) 1)2G#1 2G)4 4'2 #4'EMG B'42#42? =N 9# (' 4'2 M#2 2G1'EMG 2G#
#4231# B'E1:#C 6'E B)4 2)[# 2G# 1#*)3434M ")<: <6 6'E1:#"N ): 2G3: 34:21EB23'4)"
G)4('E2 G): :ENN3B3#42 4'2#: 2' B'*+"#2# #P#162G34M.
We hope you enjoy this couise as much as we enjoyeu putting it togethei.
Remembei - we aie heie foi you. Bon't hesitate to ask any questions uuiing the
event anu afteiwaius.
*6:;868<=5>
To take this couise, you will neeu to uownloau anu configuie the following softwaie;
A. Install anu configuie Auobe Flex Builuei S.u ANB Flash Builuei 4.u. Note: If
you ueciue to only use one of these, most of the piojects will still woik but
some will not.
B. Set up an account with Yahoo Bevelopei Netwoik anu get an API key
C. Bownloau the Yahoo SWC file
B. Bownloau the ESRI SWC file
E. Bownloau anu set up the BlazeBS Seivei incluuing configuiing youi
}AvA_B0NE anu PATB enviionmental vaiiables.
F. (0ptional) - Bownloau anu install NANP (Nac) oi WANP (Winuows). 0ne
lab iuns on NANP, LANP oi WANP but it is piobably okay if you miss that
one.
u. Receive the pioject folueis containing all the labs anu staitei files. These can
be uistiibuteu uuiing the fiist houi of the couise but piepaiation in auvance
woulu be bettei.
&57>?589 8>9 =>@<8?? %95A: %-# 3B4BC 56 ?8<:6 DE8FG *HG I=>JKL
1. If you alieauy have an eailiei veision of Auobe AIR, simple upuate it. This
shoulu happen automatically when you open an AIR application on youi
computei.
2. If you uo N0T have Auobe AIR alieauy installeu:
a. Navigate with a biowsei to http:get.auobe.comaii
b. The web page shoulu alieauy uetect youi opeiating system anu allow
you to uownloau Auobe AIR. IF you iequiie othei 0S suppoit, click
on "Biffeient 0peiating System".
c. Stait the installei anu follow the on scieen instiuctions.
u. If you have any pioblems, email unickullauobe.com. We will also be
on hanu Su minutes piioi to the lab at NAX to help with installations.
&57>?589 8>9 =>@<8?? !?8@M NJ=?9:6 O N:<8
1. uiab a biowsei anu navigate to
https:www.auobe.comcfusionentitlementinuex.cfm.e=labs_flashbuilue
i4
2. Entei youi Auobe IB (oi cieate a new one) anu answei all the questions.
S. Bownloau the installei anu follow the instiuctions on scieen.
H5J6@:786: H&
1. The couisewaie CB will be hanueu out piioi to the. Aftei that you will be able
to uownloau it fiom http:www.web2open.oig.couises.html
N?8P:&Q D";<=5>8?L
!"#$% '()*+,) (-.)/00(-1 )*(. 2,(03 +4 50/6789 :+, '(00 -+) 27 /207 )+ 3+ )*7 ;72
97<=(>7. 0/2? @+, '(00 /0.+ */=7 )+ ,.7 )*7 '72 )+ >+AB07)7 )*7 C##D 0/2? ;7
*(1*0: <7>+AA7-3 :+, (-.)/00 50/6789 (4 +- :+,< >+AB,)7< )+ <73,>7 )*7
(-)7<-7) )</44(> (- )*7 <++A 3,<(-1 )*7 0/2?
Theie aie a few labs that use iemote web iesouices. To iun the web seivice example
locally, you can use the BlazeBS seivei with Apache Axis S0AP uownloauable fiom
http:www.web2open.oigcouisesBlazeBS.zip.
X5RVY \'E *E:2 G)P# ) O)P) O8Q 34:2)""#( )4( B'4N3ME1#(? =N 6'E (' 4'2
G)P# 2G3: ('4#C 1#N#1# 2' ;++#4(3$ ; )2 2G# <)B[ 'N 2G3: ('BE*#42?
1. Bownloau anu install the zip file to youi uesktop oi othei suitable location.
2. 0nzip the uiiectoiy to youi haiu uiive anu copy the BlazeBS Root Foluei
ovei to a peimanent location on youi haiu uiive. This foluei shoulu contain
the following folueis anu files as shown below:
S. Next, stait up the BlazeBS seivei. To uo this, open a Commanu Winuow (oi
shell) anu navigate to <Course_Root>\BlazeDS\sampledb (if on 0SX,
use foiwaiu slashes insteau of back foi path).
a. 0n Winuows, type in "staitub". This shoulu stait the uatabase.
C:\Documents and
Settings\Administrator\Desktop\MAX2008_BuildingServiceClients\s
ampledb>startdb
C:\Documents and
Settings\Administrator\Desktop\MAX2008_BuildingServiceClients\s
ampledb>java -cp hsqldb.jar org.hsqldb.Server
[Server@1d58aae]: [Thread[main,5,main]]: checkRunning(false)
entered
[Server@1d58aae]: [Thread[main,5,main]]: checkRunning(false)
exited
[Server@1d58aae]: Startup sequence initiated from main() method
[Server@1d58aae]: Loaded properties from [C:\Documents and
Settings\Administrato
r\Desktop\MAX2008_BuildingServiceClients\sampledb\server.propertie
s]
[Server@1d58aae]: Initiating startup sequence...
[Server@1d58aae]: Server socket opened successfully in 40 ms.
[Server@1d58aae]: Database [index=0, id=0,
db=file:flexdemodb/flexdemodb, alias=
flexdemodb] opened sucessfully in 1512 ms.
[Server@1d58aae]: Startup sequence completed in 1552 ms.
[Server@1d58aae]: 2008-11-25 12:29:14.087 HSQLDB server 1.8.0 is
online
[Server@1d58aae]: To close normally, connect and execute SHUTDOWN
SQL
[Server@1d58aae]: From command line, use [Ctrl]+[C] to abort
abruptly
b. 0n Nac oi Linux, open a teiminal anu type suuo sh .staitub.sh
4. Now stait the seiveis.
a. 0n Winuows, uo this by changing uiiectoiies until you aie at the
<Course_Root>\BlazeDS\tomcat\bin uiiectoiy (note: use
foiwaiu slashes on 0nix baseu Systems) anu type catalina run
C:\Documents and
Settings\Administrator\Desktop\MAX2008_BuildingServiceClients\t
omcat\bin>catalina run
Using CATALINA_BASE: C:\Documents and
Settings\Administrator\Desktop\MAX2008_B
uildingServiceClients\tomcat
Using CATALINA_HOME: C:\Documents and
Settings\Administrator\Desktop\MAX2008_B
uildingServiceClients\tomcat
Using CATALINA_TMPDIR: C:\Documents and
Settings\Administrator\Desktop\MAX2008_B
uildingServiceClients\tomcat\temp
Using JRE_HOME: C:\Program Files\Java\jdk1.6.0_10
Nov 25, 2008 12:34:20 PM org.apache.catalina.core.AprLifecycleListener init
INFO: The Apache Tomcat Native library which allows optimal performance in
produ
ction environments was not found on the java.library.path: C:\Program
Files\Java
\jdk1.6.0_10\bin;.;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\CF
u
sionMX7\verity\k2\_nti40\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32
\
Wbem;C:\Program Files\ATI Technologies\ATI Control Panel;C:\Program Files\PC-
Doc
tor for Windows\services;C:\Program Files\ATI Technologies\Fire GL 3D Studio
Max
;C:\WINDOWS\Downloaded Program Files;C:\Program Files\Common
Files\MXI;C:\Progra
m Files\Common Files\Adobe\AGL;C:\Program Files\QuickTime\QTSystem\
Nov 25, 2008 12:34:20 PM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-8400
Nov 25, 2008 12:34:20 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 432 ms
Nov 25, 2008 12:34:20 PM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Nov 25, 2008 12:34:20 PM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.14
Nov 25, 2008 12:34:24 PM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-8400
Nov 25, 2008 12:34:24 PM org.apache.jk.common.ChannelSocket init
INFO: JK: ajp13 listening on /0.0.0.0:8009
Nov 25, 2008 12:34:24 PM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/20 config=null
Nov 25, 2008 12:34:24 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 3988 ms
b. 0n Nac 0SX anu Linux, uo this by changing uiiectoiies until you aie at
the <Course_Root>/BlazeDS/tomcat/bin uiiectoiy anu type
sudo sh ./catalina.sh run
S. You shoulu be able to valiuate the seiveis aie up anu iunning by hitting the
following 0RL: http:localhost:84uuxmlWines.xml
6. If you have any pioblems with this, come to the classioom eaily befoie the
bootcamp anu we will be glau to help.
->@<8??=>R 8>9 F5>S=RJ6=>R %95A: !?:K NJ=?9:6 )B/B
1. Take a biowsei anu go to
http:www.auobe.comcfusionentitlementinuex.cfm.e=flexbuilueiS anu
uownloau the Flex Builuei tiial.
2. 0pen up the uisk image anu follow the on scieen instiuctions.
S. Note wheie you set up youi woikspace. This is wheie you will place all the
files you woik on anu vaiious libiaiies neeueu foi this couise.
4. Nac 0SX: By uefault, this will be unuei youi
~home_uiiectoiyBocumentsFlex Builuei S.
S. Winuows: By uefault, this will be unuei youi c:\Piogiam Files\Auobe\Flex
Builuei S.
LIN0X 0NLY
6. Foi the Linux veision, uownloau the plugin fiom
http:labs.auobe.comuownloausflexbuiluei_linux.html.
7. Run the installei eithei maiking it as executable (chmou +x) oi by using a
shell to execute it (sh flexbuiluei_linux_install_a4_u814u8.bin).
8. When piompteu, specify whethei to install Flash Playei 9 (note that this is an
upuateu veision of Flash Playei 9 anu that Flex Builuei Linux will woik with
eailiei veisions of Flash Playei 9 foi Linux). This is the uebug veision of
Flash Playei 9, which is iequiieu foi uebugging suppoit anu exception
uisplay.
Q:< J; 8>9 8FF5J>< 7=<M T8M55 8>9 957>?589 <M: Q$H S=?:B
1. 0se youi biowsei anu navigate to https:uevelopei.yahoo.comwsiegapp
2. Sign in if you alieauy have an account oi iegistei foi a new one. If you have
alieauy iegisteieu foi an API key, you can see it via the hypeilink neai the top of the
page as shown below:
9. If you uo not have an API key, fill in the foim anu agiee to any license teims
as shown below:
1u. Click "Submit" anu a key will be geneiateu foi you. Nake suie you save it
somewheie in a text file on youi uesk.
%FF:@@=>R <M: F5>S=RJ6=>R <M: T8M55E8;@B@7F S=?:B
1. Next, you neeu to uownloau anu install the ShockWave Component (SWC) file.
Aim youi biowsei at http:uevelopei.yahoo.comflashmaps
2. Save the zip to youi haiu uiive anu open the aichive. You will see a file calleu
YahooNaps.swc insiue the zip as shown below.
S. Remembei the location of this file as you will neeu it latei.
&57>?589 <M: +Q#- %6FU-Q Q$H ?=A686VB
1. Navigate to
http:iesouices.esii.comaicgisseiveiapisflexinuex.cfm.fa=uownloauBisclaime
i
2. agiee to the teims anu conuitions of the license anu click "Bownloau" as shown
below.
S. Save the file to youi haiu uiive as you will iequiie it foi some labs.
B. 0nzip the file anu you will see a ShockWave Component file as shown below
I. Remembei the location of this file as you will neeu it foi labs 4,S,6.
D";<=5>8?L W &57>?589 8>9 =>@<8?? E%E* DE8FL 56 $%E* D$=>957@L
If you aie on a Nac, uownloau anu install NANP -
http:www.mamp.infoeninuex.html
If you aie on a Winuows Nachine, uownloau anu install WANP -
http:www.wampseivei.comen
Follow the instiuctions foi youi paiticulai opeiating system as pei the uocoments
uesciibing installation.
Auuitionally, uownloau anu install the Zenu Fiamewoik foi ANP-PBP connectivity
fiom http:www.zenu.comen
%;;:>9=K %' 08X8 0&2
&57>?589=>RG =>@<8??=>R 8>9 F5>S=RJ6=>R 08X8 0&2
This couises uses a mouifieu BlazeBS that contains some extia files not founu on the
stanuaiu BlazeBS available fiom Auobe's 0pen Souice Website. In oiuei to install
anu configuie BlazeBS, you will neeu to have a }ava }BK on youi system anu the
}AvA_B0NE Enviionmental vaiiable set piopeily as well as youi path.
X'2#Y =N 6'E )"1#)(6 G)P# O)P) O8Q .?@ /<E2 4'2 .?W7C +"#):# *'P# )G#)( 2' 2G#
4#$2 :2#+? RG3: ")< 9): 2#:2#( 932G ])P) P#1:3'4 .?@?-U.W? R' N34( 'E2 9G)2
P#1:3'4 'N O)P) 6'E G)P# '4 6'E1 :6:2#*C '+#4 E+ ) B'**)4( 934('9
/L34('9:7 '1 R#1*34)" /A)BC D34E$C ^43$7 )4( 26+# _])P) KP#1:3'4` 2G#4 G32
2G# #42#1 [#6?
If you alieauy have 1.S installeu, skip aheau to Section 2 to check classpath anu set
}AvA_B0NE.
1. Navigate with a web biowsei to
http:java.sun.comjavaseuownloausinuex_jukS.jsp
2. Navigate uown the page until you see the uownloau foi }BK S.u with }ava EE.
Click on uownloau.
S. Select the coiiect 0peiating System foi youiself, accept the license teims
then click uownloau as shown below
4. 0n the next scieen select the uownloau again anu click the button.
S. Save the files to youi uesktop, then follow the instiuctions foi youi opeiating
system to complete the installation piocess.
Q:<<=>R <M: 08X8 *%,Y 8>9 0%1%ZY"E+
This assumes you have }ava }BK 1.S installeu as pei Section 1. To test if youi path is
set piopeily, open up a commanu winuow (Winuows) oi Teiminal (Nac, Linux,
0nix) anu type "java -veision" then hit the entei key. If you see the scieen below,
youi path is set.
If you see something else, you have to set youi path.
If you woik on a Nac oi Linux machine, this is most likely alieauy up anu configuieu
piopeily so theie is no neeu to uo anything else. 0n the othei hanu, if you iun..
L34('9:
1. Click ":2)12" anu highlight "A6 &'*+E2#1" with youi mouse. Right click to
biing up the popup menu anu select "01'+#123#:" anu click on it as shown
below.
2. This will biing up a piopeities pane with seveial options. Click on the tab
labelleu "Auvanceu"
S. Click "Enviionment vaiiables". This biings up the Enviionmental vaiiables
piopeities pane. If theie is alieauy a PATB vaiiable uefineu, click on the
"Euit" button below "0sei vaiiables foi <useiname>" anu auu the path to
youi java }BK bin. If theie is no PATB vaiiable uefineu, click "New".
4. This path will be something like "c:\java1_S\juk\bin. Nake suie in that
uiiectoiy theie is a "java.exe" anu a "javac.exe" in that uiiectoiy.
S. 0nuei System vaiiables, if theie is no }AvA_B0NE vaiiable, click "New" anu
auu one. The value only have to point at the ioot uiiectoiy of youi }ava
installation. This N0ST contain a subfoluei calleu \bin. The path will be
something like c:\java1_S\juk.
6. Click "0kay" aftei auuing these vaiiables anu close all the uialogs.
7. To test, open a commanu winuow (stait -> iun -> "cmu") anu type in "java -
veision" anu hit ietuin. Then type "javac" anu hit ietuin. If you uo not get
both commanus iecognizeu as shown below, consult the Sun uocumentation
on setting the classpath foi youi system.