152
Appendix A: Basic Flex Concepts
If you hand-code your pages, you can use ActionScript or the
<mx:Model>
tag to define a data
model. In general, you should use a tag for simple data structures and ActionScript for more
complex structures and client-side business logic. However, Flex Builder only recognizes data
models defined with the
<mx:Model>
tag.
Related topics
•
“Using data models” in Developing Flex Applications Help
•
“Working with Flex data models” on page 129
Flex data services
A Flex data service is an object you insert in an MXML file to communicate with the business
layer of a multi-tier application. You use data services to send and receive data from web services,
HTTP URLs, and remote objects such as server-based Java objects.
In most enterprise applications, the presentation layer (the user interface) is separated from the
business layer containing the code that implements the functionality or business rules of the
application, and the data layer containing databases and other data stores. The presentation layer
interacts with the business and data layers to produce an integrated application.
Note:
The development of the business and data layers is beyond the scope of this guide. Flex is a
presentation technology designed to work with existing business and data layers.
As a presentation layer technology, Flex does not support direct access to databases. The code
contained in the business layer is responsible for communicating with databases. In other words,
Flex must work with the business layer to get access to the underlying data.
The Flex presentation layer communicates with the business layer by using Flex data services,
which are objects you insert in a Flex file. Specifically, you can use Flex data services to interact
with the following:
•
Web services
•
HTTP services
•
Remote objects
Summary of Contents for FLEX BUILDER-USING FLEX BUILDER
Page 1: ...Using Flex Builder...
Page 116: ...116 Chapter 4 Building a Flex User Interface Visually...
Page 144: ...144 Chapter 6 Working with Data...
Page 154: ...154 Appendix A Basic Flex Concepts...