溫馨提示:您的每一次轉(zhuǎn)載,體現(xiàn)了我寫此文的意義!!!煩請(qǐng)您在轉(zhuǎn)載時(shí)注明出處http://www.aygfsteel.com/sxyx2008/謝謝合作!!!

          雪山飛鵠

          溫馨提示:您的每一次轉(zhuǎn)載,體現(xiàn)了我寫此文的意義!!!煩請(qǐng)您在轉(zhuǎn)載時(shí)注明出處http://www.aygfsteel.com/sxyx2008/謝謝合作!!!

          BlogJava 首頁(yè) 新隨筆 聯(lián)系 聚合 管理
            215 Posts :: 1 Stories :: 674 Comments :: 0 Trackbacks
          在web.xml里配置
          <servlet>
                  
          <servlet-name>xfire</servlet-name>
                  
          <servlet-class>
                      org.springframework.web.servlet.DispatcherServlet
                  
          </servlet-class>
          </servlet>
          <servlet-mapping>
                  
          <servlet-name>xfire</servlet-name>
                  
          <url-pattern>*.ws</url-pattern>
          </servlet-mapping>
          在spring配置文件中加入以下
          <bean id="xfire.annotationServiceFactory"
                  class
          ="org.codehaus.xfire.annotations.AnnotationServiceFactory">
                  
          <constructor-arg index="0">
                      
          <ref bean="xfire.commonsAnnotations"/>
                  
          </constructor-arg>
                  
          <constructor-arg index="1">
                      
          <ref bean="xfire.transportManager"/>
                  
          </constructor-arg>
                  
          <constructor-arg index="2">
                      
          <ref bean="xfire.aegisBindingProvider"/>
                  
          </constructor-arg>
              
          </bean>

              
          <bean id="xfire.commonsAnnotations"
                  class
          ="org.codehaus.xfire.annotations.jsr181.Jsr181WebAnnotations"/>
              
              
          <bean class="org.springframework.web.servlet.handler.SimpleUrlHandlerMapping">
                  
          <property name="urlMap">
                      
          <map>
                          
          <entry key="/SynchronizService.ws">
                              
          <ref bean="synchronizservice"/>
                          
          </entry>
                      
          </map>
                  
          </property>
              
          </bean>
              
              
          <bean name="synchronizservice" class="org.codehaus.xfire.spring.remoting.XFireExporter">
                  
          <property name="serviceBean" ref="synchronizserviceBean"/>
                  
          <property name="serviceClass"><value>com.futuresoftware.webservices.SynchronizService</value></property>
                  
          <property name="serviceFactory" ref="xfire.annotationServiceFactory"/>
                
          </bean>

                
          <bean id="synchronizserviceBean" class="com.futuresoftware.webservices.SynchronizServiceImpl"/>

          以上是基于注解方式的配置具體配置可參考
          http://xfire.codehaus.org/Advanced+Configuration

          posted on 2011-06-15 10:03 雪山飛鵠 閱讀(731) 評(píng)論(0)  編輯  收藏 所屬分類: webservice
          主站蜘蛛池模板: 乐都县| 庆元县| 中阳县| 青阳县| 社旗县| 吴江市| 清流县| 襄城县| 清涧县| 彰武县| 清原| 新余市| 马山县| 渭南市| 新巴尔虎右旗| 米易县| 岳普湖县| 杭锦后旗| 同德县| 剑川县| 岳池县| 郧西县| 珲春市| 江陵县| 梨树县| 永年县| 永靖县| 郸城县| 新建县| 大悟县| 西乌珠穆沁旗| SHOW| 绥德县| 广昌县| 仲巴县| 农安县| 泰宁县| 古蔺县| 板桥市| 霞浦县| 星子县|