Axis2实践
发布时间:2020-12-17 01:04:18 所属栏目:安全 来源:网络整理
导读:以前开发webservice使用IBM工具比较简单,最近重新感觉一下使用AXIS2。 基本步骤: 1 eclipse 2 axis2文件 3 tomcat容器/jetty 创建javaBean,反向为wsdl,同时使用wsdl制作client。 http://localhost/a/services/TestCal? TestCal Hi there,this is an AXIS
以前开发webservice使用IBM工具比较简单,最近重新感觉一下使用AXIS2。
基本步骤:
1 eclipse
2 axis2文件
3 tomcat容器/jetty
创建javaBean,反向为wsdl,同时使用wsdl制作client。
http://localhost/a/services/TestCal?
TestCalHi there,this is an AXIS service! Perhaps there will be a form for invoking the service here...
http://localhost/a/services/TestCal?wsdl
This XML file does not appear to have any style information associated with it. The document tree is shown below.
package com.rx;
import java.rmi.RemoteException; public class MyTest { /** * @param args * @throws RemoteException? */ public static void main(String[] args) throws RemoteException { TestCal testCal = new TestCalProxy(); System.out.println(testCal.say("bdfdfa")); } }
war部署到容器中。
客户端测试代码
在tomcat和jetty(D:jetty-6.1.6>java -jar start.jar)下都测试通过。
下面的推荐我没仔细看,瞄了一眼, 感觉还比较全。
推荐:http://sumdwang.blog.163.com/blog/static/7929695020113281127488/(编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |