zoukankan      html  css  js  c++  java
  • xfire配置(java中的webservice)

    开发时需要在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

    .net调用:http://localhost:8080/ws/services/DischargeService?wsdl

    java调用:http://localhost:8080/ws/services/DischargeService

  • 相关阅读:
    实验三 进程调度模拟程序
    实验二作业调度模拟程序实验报告
    实验8
    实验七
    实验六
    实验五 数独游戏界面设置
    实验五
    实验四
    实验三
    实验二
  • 原文地址:https://www.cnblogs.com/Anders888/p/5087891.html
Copyright © 2011-2022 走看看