Data Translation - MACROMEDIA COLDFUSION MX 7.0.2-USING COLDFUSION MX WITH FLEX 2 Use Manual

Table of Contents

Advertisement

The session ID is the client ID assigned to your Flex application. Reloading the Flex
application starts a new session with a new session ID.
To set credentials in a message in Flex, before sending the message through the gateway to the
CFC, you use the
setRemoteCredentials
var msg:Message = new AsyncMessage();
msg.body = input.text;
msg.headers.gatewayID = "Flex2CF";
msg.setRemoteCredentials("mycfusername", "mycfpassword");
To authenticate the credentials sent in the message, in an Application.cfm or Application.cfc
file, you use the
cflogin
<cfapplication name="authenticateuser" sessionmanagement="yes">
<cflogin>
<cfif isDefined("cflogin.name") or isDefined("cflogin.password")>
<cfloginuser name="#cflogin.name#" password="#cflogin.password#"
roles="#roles#">
</cfif>
</cflogin>

Data translation

The following table lists the ColdFusion data types and the corresponding Adobe Flash or
ActionScript data type:
ColdFusion data type
String
Array
Struct
Query
CFC
CFC Date
CFC String
CFC Numeric
ColdFusion XML Object
method, as follows:
tag, as follows:
Flash data type
String
[] = Array
{} = untyped Object
Array of untyped Objects
Class = typed Object (if a matching ActionScript class
exists, otherwise the CFC becomes a generic untyped
Object (map) in ActionScript)
ActionScript Date
ActionScript String
ActionScript Numeric
ActionScript XML Object

Data translation

23

Advertisement

Table of Contents
loading

This manual is also suitable for:

Coldfusion mx

Table of Contents