Satya Aravind Kopparthi Weblog

03/08/2009

Building Flex Applications using Cairngorm with Maven 2.

Filed under: Flex — akopparthi @ 3:50 pm

There is a lot of documentation already out there for Cairngorm but many of the basic examples on the web (and especially on labs.adobe.com) are now slightly out of date, and use deprecated methods. I expect it can be a little frustrating for someone coming in to Cairngorm for the first time, especially if you have not used anything similar before, so this should be a good next step for you if you have already read the docs, understand the basic concepts and want an aid to help speed up your understanding


Step 1: Download Cairngorm swc component

The first thing to do is download the Cairngorm binary and a Cairngorm example application. I’m currently using FlexBuilder3 beta (Moxie), and so I decided to go with the latest version of Cairngorm which is 2.2. Due to issues with a recent FlexBuilder hotfix I’ve downloaded a beta version called 2.2.1_beta. The best thing to do is look at the Cairngorm wiki on Adobe.labs to ensure you get the correct version for you:

http://opensource.adobe.com/wiki/display/cairngorm/Downloads

Step 2: Install using mvn

mvn install:install-file -DgroupId=com.adobe.flex.framework -DartifactId=cairngorm-framework-Dversion=2.2.1 -Dpackaging=jar -Dfile=c:\cairngorm.swc

Step 3: Reference the installed component in pom

<dependency>
<groupId>  com.adobe.flex.framework </groupId>
<artifactId>cairngorm-framework </artifactId>
<version>2.2.1</version>
<type>swc</type>

</dependency>

Step 4: Download the example

You can view the Diagram Explorer here, view the example app here and download the example app here.

Good luck.

No Comments Yet »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a comment

Blog at WordPress.com.