Installing ConduitThe following steps should get you up and running with Conduit in no time! Library Installation
You now have all the right libraries, in the right places. Configuration
<adapter-definition id="conduit" class="com.compoundtheory.conduit.adapters.ColdFusionAdapter"/>
<destination id="Conduit">
<channels>
<channel ref="my-cfamf" />
</channels>
<adapter ref="conduit" />
<properties>
<source>*</source>
<cfcs>
<!--
Whether or not reload the CFCs below on each request.
Useful for debugging when building new invokers,serialisers
or deserialisers
-->
<reloadcfcs>false</reloadcfcs>
<!--
The CFC that invokes the remote method call
-->
<invoker>conduit.core.CFCInvoker</invoker>
<!--
Translates CF=>AS3
-->
<serialiser>conduit.core.CFSerialiser</serialiser>
<!--
Translates AS3=>CF
-->
<deserialiser>conduit.core.CFDeserialiser</deserialiser>
</cfcs>
<access>
<!--
allow "public" (which is public or remote) or just "remote" methods to be invoked.
If not specified, "remote" is the default
-->
<method-access-level>remote</method-access-level>
</access>
</properties>
</destination>
An example of the remoting-config.xml can be found in the download zip file, under /config. This creates a Destination for the general invokers, serialiser and deserialiser that ships with Conduit.
Usage within Flex
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical" creationComplete="init();">
<mx:RemoteObject id="service" destination="Conduit" source="flexrecursive.Remote">
<mx:method name="doSomething()" fault="onFault(event);" result="onResult(event);" />
</mx:RemoteObject>
<mx:Script>
private function init():void
{
service.doSomething();
}
private function onResult(event:ResultEvent):void
{
//do something
}
</mx:Script>
</mx:Application>
Installation IssuesIf you have any problems, please refer to Debugging with Conduit, and/or post to the mailing list. |