码迷,mamicode.com
首页 > 编程语言 > 详细

xfire配置(java中的webservice)

时间:2015-12-30 10:38:15      阅读:146      评论:0      收藏:0      [点我收藏+]

标签:

开发时需要在src中新建META-INF=>xfire=>services.xml 这样编译出来就在classes文件夹下。

services.xml配置

<?xml version="1.0" encoding="UTF-8"?>  
<beans>  
<service  xmlns="http://xfire.codehaus.org/config/1.0">  
    <name>DeviceService</name>  
    <serviceClass>com.ws.service.IDevice</serviceClass>  
    <implementationClass>com.ws.serviceImp.DeviceService</implementationClass>  
</service>   
<service  xmlns="http://xfire.codehaus.org/config/1.0">  
    <name>RealWarnService</name>  
    <serviceClass>com.ws.service.IRealWarn</serviceClass>  
    <implementationClass>com.ws.serviceImp.RealWarnService</implementationClass>
</service>
<service  xmlns="http://xfire.codehaus.org/config/1.0">
    <name>RealDataService</name>
    <serviceClass>com.ws.service.IRealData</serviceClass>  
    <implementationClass>com.ws.serviceImp.RealDataService</implementationClass>
</service>
<service   xmlns="http://xfire.codehaus.org/config/1.0">
    <name>BatteryService</name>
    <serviceClass>com.ws.service.IBatteryService</serviceClass>  
    <implementationClass>com.ws.serviceImp.BatteryService</implementationClass>
</service> 
<service   xmlns="http://xfire.codehaus.org/config/1.0">
<name>DischargeService</name>
    <serviceClass>com.ws.service.IDischarge</serviceClass>  
    <implementationClass>com.ws.serviceImp.DischargeService</implementationClass>
</service>
</beans>  

测试网址:http://localhost:8080/ws/services/DischargeService?wsdl

xfire配置(java中的webservice)

标签:

原文地址:http://www.cnblogs.com/Anders888/p/5087891.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!