日期:2014-05-18 浏览次数:20749 次
<display-name>BlazeDS</display-name>
<description>BlazeDS Application</description>
<servlet>
<servlet-name>MessageBrokerServlet</servlet-name>
<display-name>MessageBrokerServlet</display-name>
<servlet-class>flex.messaging.MessageBrokerServlet</servlet-class>
<init-param>
<param-name>services.configuration.file</param-name>
<param-value>/WEB-INF/flex/services-config.xml</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>MessageBrokerServlet</servlet-name>
<url-pattern>/messagebroker/*</url-pattern>
</servlet-mapping>
<default-channels>
<channel ref="my-amf"/>
</default-channels>
<destination id="ssh_flex">
<adapter ref="java-object" />
<properties>
<source>com.text.SSHFlex</source>
</properties>
</destination>
protected function application1_creationCompleteHandler():void
{
text_flex.sayHello("helloWorld");
}
<fx:Declarations>
<!-- 将非可视元素(例如服务、值对象)放在此处 -->
<s:RemoteObject id="text_flex" showBusyCursor="true" destination="ssh_flex"
result="text_resultHandler(event)"
fault="text_faultHandler(event)" endpoint="http://127.0.0.1/Test/messagebroker/amf"/>
</fx:Declarations>