Developing Flex RIAs with Cairngorm microarchitecture

          What is Cairngorm?

Cairngorm is fundamentally a methodology for breaking up your

application code by logical functions; by data, by user views, and by the code that

controls everything. This is routinely referred to as MVC.

 

The Pieces of Cairngorm
· Model Locator: Stores all of your application’s Value Objects (data) and
shared variables, in one place. Similar to an HTTP Session object, except that
its stored client side in the Flex interface instead of server side within a
middle tier application server.
· View: One or more Flex components (button, panel, combo box, Tile, etc)
bundled together as a named unit, bound to data in the Model Locator, and
generating custom Cairngorm Events based on user interaction (clicks,
rollovers, dragndrop.)
· Front Controller: Receives Cairngorm Events and maps them to Cairngorm
Commands.
· Command: Handles business logic, calls Cairngorm Delegates and/or other
Commands, and updates the Value Objects and variables stored in the Model
Locator
· Delegate: Created by a Command, they instantiate remote procedure calls
(HTTP, Web Services, etc) and hand the results back to that Command.
· Service: Defines the remote procedure calls (HTTP, Web Services, etc) to
connect to remote data stores.

 

Fit All the Pieces Together

Your client interface is comprised of Views. The Views use Flex binding to display data contained in the Model Locator.

The Views generate Events based on user gestures such as mouse click, button press, and drag & drop.

Those Events are “broadcast” and “heard” by the Front Controller, which is a map of Events to Commands.

Commands contain business logic, create Delegates to perform work, handle responses from Delegates,

and update the data stored in the Model Locator. Since Views are bound to the data in the Model Locator the Views
automatically update when the Model Locator data is changed.

Delegates call Services and hand results back to Commands, and are optional but recommended.
Services make remote data calls and hand the results back to Delegates.

 

 

Read more :

 

1. good article, explains how to build Flex Application with Cairngorm micro architecture :

www.adobe.com/devnet/flex/articles/cairngorm_pt1.html

The presentation demonstrates  a real life example Cairngorm Store which includes J2EE container and Flex Data Services/ Java.

If you still want to run this application but without the J2EE container part (Mockup data),

Check the ntier.wordpress.com/modcairngormstore/ example

 

2. www.digimmersion.com/support/Flex%20UI%20Design%20For%20Cairngorm.pdf

 

 

Thank you for your interest!

We will contact you as soon as possible.

Send us a message

Oops, something went wrong
Please try again or contact us by email at info@tikalk.com