Adobe 38043740 - ColdFusion Standard - Mac Development Manual page 659

Developing applications
Hide thumbs Also See for 38043740 - ColdFusion Standard - Mac:
Table of Contents

Advertisement

DEVELOPING COLDFUSION 9 APPLICATIONS
Flex and AIR Integration in ColdFusion
• Document (cfdocument)
• Image (cfimage)
• Mail (cfmail)
• PDF (cfpdf)
• Pop (cfpop)
These classes are part of coldfusion.service.mxml package, distributed in the cfservices.swc file. You normally use these
classes in MXML tag format, using the cf namespace identifier, as in the following line:
<cf:Image id="image" action="AddBorder" source="Uploaded Image server URL" thickness="5"
color="Blue"/>
To use a ColdFusion service in an application built with Flex, you use the Config class to establish the connection, and
then use the other classes to access the ColdFusion services.
In ColdFusion 9, you can also specify the remoting destination in the Config class as well as all the proxy tags.
Note: To use ColdFusion services from Flex and AIR, you must enable access to the services as described in "Enable
ColdFusion Services" in the ColdFusion Web Services section.
About the cfservices.swc file
To use any ColdFusion service class in an application built with Flex/AIR, do the following:
Include the cfservices.swc file, located at /CFIDE/scripts/AIR/cfservices.swc, in your application
1
In Flash Builder, add the cfservices.swc file to your project by right-clicking Flex/AIR Project > Properties >Flex
2
BuildPath >Library Path >Add SWC.
For details on all ColdFusion service classes, and other classes in the coldfusion.air package, see
Reference. Alternatively, you can see the standalone Adobe ColdFusion ActionScript Language Reference, which is
accessible through the Documentation link on the Resources page of the ColdFusion Administrator.
For information about attributes for specific services, such as Mail or Pop, see the attributes of corresponding
ColdFusion tags and functions.
Using the Config class
Use the Config class to set the configuration parameters for ColdFusion Services, including the connection details and
event handlers. Therefore, use the Config class before using any of the service classes. The parameters set on the Config
class are global and can be overridden by the individual service proxy classes.
The following table lists the Config class parameters, normally used as attributes of a Config tag.
Attribute
Description
serviceUserName
The userName set in the ColdFusion Administrator with the permission to access the specific service being
requested.
servicePassword
The password set in the ColdFusion Administrator for the user name.
cfServer
The server name or IP address of the CF server.
cfPort
The port on which the CF Server is running.
Last updated 1/20/2012
654
ActionScript 3.0

Advertisement

Table of Contents
loading

This manual is also suitable for:

Coldfusion 9

Table of Contents