jbossws快速入门
jbossws实现JAX-WS规范,使用该工具开发web service非常简单。该工具由jboss jee5服务器提供,内置在jboss4.2、jboss5。如果你对该项目有兴趣,可以到[url="http://www.jboss.org/jbossws]jbossws[/url]的站点了解更多的信息。 [b]Web Service Endpoint[/b] [code="java"] package helloservice; @javax.jws.WebService( serviceName="HelloService", name="Hello", targetNamespace="http://www.jboss.org/example") public class HelloBean { private String message = new String("Hello, "); @javax.jws.WebMethod public String sayHello(String name) { return message + name + "."; } } [/code] [b]Web Service Deploy[/b] web.xml加入 [code="xml"] HelloService helloservice.HelloBean HelloService /hello [/code] 部署在jboss并启动,访问http://localhost:8080/jbossws/,点击View a list of deployed services的链接就可以看到部署好的web service. 可见,比起jax-rpc,开发效率大大提高。
问一下,用这个JBossWS开发webservice,开发环境怎么配置呀 就是在MyEclipse的工程中,应该引用哪些JAR包 谢谢
很好。学习一下。
帅哥,不错哦