MACROMEDIA COLDFUSION MX 7.0.2-USING COLDFUSION MX WITH FLEX 2 Use Manual page 42

Table of Contents

Advertisement

The sample services-config.xml file is located in the C:\fds2\resources\config folder, and
the web application flex-messaging-service.xml file is located in the
C:\fds2\jrun4\servers\default\samples\WEB-INF\flex folder when you install Flex in the
default location.
(Optional) Turn on the ColdFusion-specific debugging output in the Flex console by
2.
adding the following <pattern> tag in the <filters> tag in the <logging> section of the web
application services-config.xml file:
<pattern>DataService.coldfusion</pattern>
Add the coldfusion-dao adapter to the web application data-management-config.xml (in
3.
the C:\fds2\jrun4\servers\default\samples\WEB-INF\flex folder when you install Flex in
the default location) by adding the following in the <adapters> section:
<adapter-definition id="coldfusion-dao"
class="coldfusion.flex.CFDataServicesAdapter"/>
For more information, see "Configuring the Data Service" in Developing Flex Applications,
which is included in the Flex documentation.
The ColdFusion MX Administrator lets you enable or disable Flex Data Management
support. If you are running more than one instance of ColdFuison, you must use a unique
ID to specify each instance of ColdFusion for which you want to enable Flex Data
Management support. You do so by specifying the identity in the <identity> element of the
data-management-config.xml file.
Writing the ColdFusion CFCs
The Flex Data Management Service recognizes the methods:
The
method retrieves records from a database and populates an array with the records.
fill
The
method retrieves a specific record. The
get
synchronization conflicts by accepting a change list, which is an array of change objects. The
method returns a number that indicates how many records are in a result set. To
count
perform any of these database tasks, the Flex application calls the appropriate
, or
method in the assembler CFC. You can also use a
sync
count
which checks whether to update the results of a fill. For more information, see
fills" on page
43.
When you create the ColdFusion CFC, you include the database manipulation in the
methods in the assembler CFC or use the Bean/DAO methodology. For more information,
see
"Selecting a methodology" on page
42
Using the Flex Data Service Assembler
method lets you keep track of
sync
43.
,
,
, and
fill
get
sync
fill
method,
fillContains
"Managing
.
count
,
,
get

Advertisement

Table of Contents
loading

This manual is also suitable for:

Coldfusion mx

Table of Contents