you can change the styles used by your application, in addition to the language used, based on the locale.
2: Flex Application Design for Cairngorm
Overview of Cairngorm Although this document attempts to cover the basics of planning a Cairngorm application, it does not go into any deep framework detail. For further information and code example on Cairngorm see Steven Webster’s blog, the Cairngorm Wiki on Adobe Labs, or the Yahoo! FlexCoders group. 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, or Model, View, and Control.
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, drag and drop.) · 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.
How the Pieces Fit Together Cairngorm basically works like this: 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.
METAOPTION LLC, 574 NEWARK AVENUE, SUITE 210 JERSEY CITY, NJ 07306; PH: 201-377-3150 EMAIL: firstname.lastname@example.org: WEB SITE: www.metaoption.com