1.下载Blazeds.war;并解压
2.新建一个Web工程
3.拷贝解压后的Blazeds下的WEB_INF文件下下的flex、lib、web.xml 到新建web工程的webapp下的WEB-INF目录下
4.把Flex工程的编译文件放到webapp下
5、新建提供服务的java类,如:com.skydream.appsevice.LogService
6.修改remote-config.xml文件配置,在service节点下加入
<destination id="logSerive">
<properties>
<source>com.skydream.appsevice.LogService</source>
</properties>
</destination>
7.在需要访问的mxml文件中加入RemoteObject节点,如下
<mx:RemoteObject id="log" destination="logSerive" fault="logFaultHandler(event)" result="resultHander(event)" />
前者是出错后的处理函数,后者是成功结果处理函数
8.在需要使用的地方:log.methed(param[]);
9.更新web工程下的flex编译文件
ok。