Web Service服务器搭建

2025-09-27 07:21:33

1、选择 Web Service Project

Web Service服务器搭建

2、工程名 demo

其他按图

Web Service服务器搭建

3、Finish

 

然后 写 一个接口和一个实现类 ;

Web Service服务器搭建

4、选择 New Web Service

Web Service服务器搭建

5、如图

然后next

Web Service服务器搭建

6、name 为 webserviec 的名称

Service interface 为 接口名

Service Impl . class 为接口实现类名

下面两个 这样选 是为 跨语言和全局共享webservice

Finish

然后 好了,加载到tomcat下

请注意 tomcat下是否有

apache-tomcat-7.0.4\webapps\demo\WEB-INF\classes\META-INF\xfire\services.xml

如没有 ,请看路径自己将工程下的services 粘贴过去

然后启动tomcat

http://localhost:8080/demo/services/   链接为 webservice的 展示列表,有多个展示多个

http://localhost:8080/demo/services/name?wsdl  为具体哪个webservice的 wsdl

Wsdl 用来传值的,不同wsdl ,有不同的作用,如增用一个wsdl,改用一个wsdl,

这个具体情况具体定义

Web Service服务器搭建

声明:本网站引用、摘录或转载内容仅供网站访问者交流或参考,不代表本站立场,如存在版权或非法内容,请联系站长删除,联系邮箱:site.kefu@qq.com。
猜你喜欢