- 浏览: 64710 次
- 性别:
- 来自: 福州
最新评论
-
mx675641819:
可以用!感谢楼主分享
JavaMai——邮箱验证用户注册 -
pangpang514:
...
javascript之eval函数 -
忆梦竹:
刘晓晓 写道你好,我在做一个课题,想自己制作张地图,并在安卓中 ...
ArcGIS在Android的应用 -
zdp510147278:
asdasd asdasdasdasd
ArcGIS在Android的应用 -
刘晓晓:
你好,我在做一个课题,想自己制作张地图,并在安卓中运用。我想问 ...
ArcGIS在Android的应用
Web Service学习小结——JAX-WS CXF AXIS2关系
Web Service是一种能够使应用程序在不同的平台使用不同的编程语言进行通讯的技术规范,而这种技术规范的实现可以用不同的方法,比如使用基于XML形式的协议(SOAP)进行通讯或者是RESTFUL形式的。
既然我们知道可以使用上面的两种形式进行通讯,那么我们就需要对上面的两种形式进行描述,规范化。而这些规范化的工作sun已经帮我们完成了,也就是 JAX-WS,JAX-RS这两种规范。
对于JAX-RS我现在没怎么了解,主要讲讲JAX-WS。
JAX-WS是一种规范,而在jdk1.6之后就有了自带的实现,但是这种实现是比较简单的,基本上就只能够传递SOAP协议格式的消息。这就是为什么我们可以在没有axis2或者CXF的情况下开发Web Service。 这时候我们就会想了,如果我们需要其他的服务,比如我想让JAX-WS与Spring集成。这种需求前辈都已经考虑过了,也实现了,不需要我们在去实现这样的需求。而这种需求的解决方案在JAX-WS中是采用框架。而JAX-WS的框架就有AXIS2和CXF。框架使用起来可能会更加灵活,功能更加强大。比如CXF不仅仅实现JAX-WS,也实现了JAX-RS规范。
楼主非常热心,非常感谢!
正如上个回复说的,我还没比较清楚的了解web service。不过我知道axis2和cxf分别是apache两个团队在维护的。具体里面怎么实现的没有看过源码,不懂。
下面是我之前看过的一篇关于axis2和CXF的比较。你参考下:
http://stackoverflow.com/questions/1243247/difference-between-apache-cxf-and-axis/1245386#1245386
兄弟,对于web service我也是刚刚才要入门,这回估计还在门口晃悠呢。
不过对于你的问题,我网上搜索了一下。也看到一个帖子相当带劲。
http://blog.csdn.net/jackphang/article/details/8793993
你可以参照里面的讲解进行操作。我试过了一遍,可行。
顺带着我把我的代码附上,你如果不想修改,直接copy这份就得了。
既然我们知道可以使用上面的两种形式进行通讯,那么我们就需要对上面的两种形式进行描述,规范化。而这些规范化的工作sun已经帮我们完成了,也就是 JAX-WS,JAX-RS这两种规范。
对于JAX-RS我现在没怎么了解,主要讲讲JAX-WS。
JAX-WS是一种规范,而在jdk1.6之后就有了自带的实现,但是这种实现是比较简单的,基本上就只能够传递SOAP协议格式的消息。这就是为什么我们可以在没有axis2或者CXF的情况下开发Web Service。 这时候我们就会想了,如果我们需要其他的服务,比如我想让JAX-WS与Spring集成。这种需求前辈都已经考虑过了,也实现了,不需要我们在去实现这样的需求。而这种需求的解决方案在JAX-WS中是采用框架。而JAX-WS的框架就有AXIS2和CXF。框架使用起来可能会更加灵活,功能更加强大。比如CXF不仅仅实现JAX-WS,也实现了JAX-RS规范。
评论
4 楼
sswh
2013-06-05
忆梦竹 写道
正如上个回复说的,我还没比较清楚的了解web service。不过我知道axis2和cxf分别是apache两个团队在维护的。具体里面怎么实现的没有看过源码,不懂。
下面是我之前看过的一篇关于axis2和CXF的比较。你参考下:
http://stackoverflow.com/questions/1243247/difference-between-apache-cxf-and-axis/1245386#1245386
下面是我之前看过的一篇关于axis2和CXF的比较。你参考下:
http://stackoverflow.com/questions/1243247/difference-between-apache-cxf-and-axis/1245386#1245386
楼主非常热心,非常感谢!
3 楼
忆梦竹
2013-06-05
sswh 写道
AXIS2和CXF之间有什么渊源吗?还是两个完全不同的实现?
举例来说:对于 http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx?wsdl
使用JDK6 的 wsimport、或者 CXF 的wsdl2java 解析都报错。
但是axis2可以识别。
~~~~~~~~~~
AXIS2比CXF和JDK自带的WebService功能都要更加完善吗?
举例来说:对于 http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx?wsdl
使用JDK6 的 wsimport、或者 CXF 的wsdl2java 解析都报错。
引用
undefined element declaration 's:schema'
但是axis2可以识别。
~~~~~~~~~~
AXIS2比CXF和JDK自带的WebService功能都要更加完善吗?
正如上个回复说的,我还没比较清楚的了解web service。不过我知道axis2和cxf分别是apache两个团队在维护的。具体里面怎么实现的没有看过源码,不懂。
下面是我之前看过的一篇关于axis2和CXF的比较。你参考下:
http://stackoverflow.com/questions/1243247/difference-between-apache-cxf-and-axis/1245386#1245386
2 楼
忆梦竹
2013-06-05
sswh 写道
AXIS2和CXF之间有什么渊源吗?还是两个完全不同的实现?
举例来说:对于 http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx?wsdl
使用JDK6 的 wsimport、或者 CXF 的wsdl2java 解析都报错。
但是axis2可以识别。
~~~~~~~~~~
AXIS2比CXF和JDK自带的WebService功能都要更加完善吗?
举例来说:对于 http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx?wsdl
使用JDK6 的 wsimport、或者 CXF 的wsdl2java 解析都报错。
引用
undefined element declaration 's:schema'
但是axis2可以识别。
~~~~~~~~~~
AXIS2比CXF和JDK自带的WebService功能都要更加完善吗?
兄弟,对于web service我也是刚刚才要入门,这回估计还在门口晃悠呢。
不过对于你的问题,我网上搜索了一下。也看到一个帖子相当带劲。
http://blog.csdn.net/jackphang/article/details/8793993
你可以参照里面的讲解进行操作。我试过了一遍,可行。
顺带着我把我的代码附上,你如果不想修改,直接copy这份就得了。
<?xml version="1.0" encoding="utf-8"?> <wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://WebXml.com.cn/" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" targetNamespace="http://WebXml.com.cn/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> <wsdl:types> <s:schema elementFormDefault="qualified" targetNamespace="http://WebXml.com.cn/"> <s:element name="getRegionDataset"> <s:complexType /> </s:element> <s:element name="getRegionDatasetResponse"> <s:complexType> <s:sequence> <s:element minOccurs="0" maxOccurs="1" name="getRegionDatasetResult"> <s:complexType> <s:sequence> <s:any minOccurs="2" maxOccurs="2" /> </s:sequence> </s:complexType> </s:element> </s:sequence> </s:complexType> </s:element> <s:element name="getRegionProvince"> <s:complexType /> </s:element> <s:element name="getRegionProvinceResponse"> <s:complexType> <s:sequence> <s:element minOccurs="0" maxOccurs="1" name="getRegionProvinceResult" type="tns:ArrayOfString" /> </s:sequence> </s:complexType> </s:element> <s:complexType name="ArrayOfString"> <s:sequence> <s:element minOccurs="0" maxOccurs="unbounded" name="string" nillable="true" type="s:string" /> </s:sequence> </s:complexType> <s:element name="getRegionCountry"> <s:complexType /> </s:element> <s:element name="getRegionCountryResponse"> <s:complexType> <s:sequence> <s:element minOccurs="0" maxOccurs="1" name="getRegionCountryResult" type="tns:ArrayOfString" /> </s:sequence> </s:complexType> </s:element> <s:element name="getSupportCityDataset"> <s:complexType> <s:sequence> <s:element minOccurs="0" maxOccurs="1" name="theRegionCode" type="s:string" /> </s:sequence> </s:complexType> </s:element> <s:element name="getSupportCityDatasetResponse"> <s:complexType> <s:sequence> <s:element minOccurs="0" maxOccurs="1" name="getSupportCityDatasetResult"> <s:complexType> <s:sequence> <s:any minOccurs="2" maxOccurs="2" /> </s:sequence> </s:complexType> </s:element> </s:sequence> </s:complexType> </s:element> <s:element name="getSupportCityString"> <s:complexType> <s:sequence> <s:element minOccurs="0" maxOccurs="1" name="theRegionCode" type="s:string" /> </s:sequence> </s:complexType> </s:element> <s:element name="getSupportCityStringResponse"> <s:complexType> <s:sequence> <s:element minOccurs="0" maxOccurs="1" name="getSupportCityStringResult" type="tns:ArrayOfString" /> </s:sequence> </s:complexType> </s:element> <s:element name="getWeather"> <s:complexType> <s:sequence> <s:element minOccurs="0" maxOccurs="1" name="theCityCode" type="s:string" /> <s:element minOccurs="0" maxOccurs="1" name="theUserID" type="s:string" /> </s:sequence> </s:complexType> </s:element> <s:element name="getWeatherResponse"> <s:complexType> <s:sequence> <s:element minOccurs="0" maxOccurs="1" name="getWeatherResult" type="tns:ArrayOfString" /> </s:sequence> </s:complexType> </s:element> <s:element name="DataSet" nillable="true"> <s:complexType> <s:sequence> <s:any minOccurs="2" maxOccurs="2" /> </s:sequence> </s:complexType> </s:element> <s:element name="ArrayOfString" nillable="true" type="tns:ArrayOfString" /> </s:schema> </wsdl:types> <wsdl:message name="getRegionDatasetSoapIn"> <wsdl:part name="parameters" element="tns:getRegionDataset" /> </wsdl:message> <wsdl:message name="getRegionDatasetSoapOut"> <wsdl:part name="parameters" element="tns:getRegionDatasetResponse" /> </wsdl:message> <wsdl:message name="getRegionProvinceSoapIn"> <wsdl:part name="parameters" element="tns:getRegionProvince" /> </wsdl:message> <wsdl:message name="getRegionProvinceSoapOut"> <wsdl:part name="parameters" element="tns:getRegionProvinceResponse" /> </wsdl:message> <wsdl:message name="getRegionCountrySoapIn"> <wsdl:part name="parameters" element="tns:getRegionCountry" /> </wsdl:message> <wsdl:message name="getRegionCountrySoapOut"> <wsdl:part name="parameters" element="tns:getRegionCountryResponse" /> </wsdl:message> <wsdl:message name="getSupportCityDatasetSoapIn"> <wsdl:part name="parameters" element="tns:getSupportCityDataset" /> </wsdl:message> <wsdl:message name="getSupportCityDatasetSoapOut"> <wsdl:part name="parameters" element="tns:getSupportCityDatasetResponse" /> </wsdl:message> <wsdl:message name="getSupportCityStringSoapIn"> <wsdl:part name="parameters" element="tns:getSupportCityString" /> </wsdl:message> <wsdl:message name="getSupportCityStringSoapOut"> <wsdl:part name="parameters" element="tns:getSupportCityStringResponse" /> </wsdl:message> <wsdl:message name="getWeatherSoapIn"> <wsdl:part name="parameters" element="tns:getWeather" /> </wsdl:message> <wsdl:message name="getWeatherSoapOut"> <wsdl:part name="parameters" element="tns:getWeatherResponse" /> </wsdl:message> <wsdl:message name="getRegionDatasetHttpGetIn" /> <wsdl:message name="getRegionDatasetHttpGetOut"> <wsdl:part name="Body" element="tns:DataSet" /> </wsdl:message> <wsdl:message name="getRegionProvinceHttpGetIn" /> <wsdl:message name="getRegionProvinceHttpGetOut"> <wsdl:part name="Body" element="tns:ArrayOfString" /> </wsdl:message> <wsdl:message name="getRegionCountryHttpGetIn" /> <wsdl:message name="getRegionCountryHttpGetOut"> <wsdl:part name="Body" element="tns:ArrayOfString" /> </wsdl:message> <wsdl:message name="getSupportCityDatasetHttpGetIn"> <wsdl:part name="theRegionCode" type="s:string" /> </wsdl:message> <wsdl:message name="getSupportCityDatasetHttpGetOut"> <wsdl:part name="Body" element="tns:DataSet" /> </wsdl:message> <wsdl:message name="getSupportCityStringHttpGetIn"> <wsdl:part name="theRegionCode" type="s:string" /> </wsdl:message> <wsdl:message name="getSupportCityStringHttpGetOut"> <wsdl:part name="Body" element="tns:ArrayOfString" /> </wsdl:message> <wsdl:message name="getWeatherHttpGetIn"> <wsdl:part name="theCityCode" type="s:string" /> <wsdl:part name="theUserID" type="s:string" /> </wsdl:message> <wsdl:message name="getWeatherHttpGetOut"> <wsdl:part name="Body" element="tns:ArrayOfString" /> </wsdl:message> <wsdl:message name="getRegionDatasetHttpPostIn" /> <wsdl:message name="getRegionDatasetHttpPostOut"> <wsdl:part name="Body" element="tns:DataSet" /> </wsdl:message> <wsdl:message name="getRegionProvinceHttpPostIn" /> <wsdl:message name="getRegionProvinceHttpPostOut"> <wsdl:part name="Body" element="tns:ArrayOfString" /> </wsdl:message> <wsdl:message name="getRegionCountryHttpPostIn" /> <wsdl:message name="getRegionCountryHttpPostOut"> <wsdl:part name="Body" element="tns:ArrayOfString" /> </wsdl:message> <wsdl:message name="getSupportCityDatasetHttpPostIn"> <wsdl:part name="theRegionCode" type="s:string" /> </wsdl:message> <wsdl:message name="getSupportCityDatasetHttpPostOut"> <wsdl:part name="Body" element="tns:DataSet" /> </wsdl:message> <wsdl:message name="getSupportCityStringHttpPostIn"> <wsdl:part name="theRegionCode" type="s:string" /> </wsdl:message> <wsdl:message name="getSupportCityStringHttpPostOut"> <wsdl:part name="Body" element="tns:ArrayOfString" /> </wsdl:message> <wsdl:message name="getWeatherHttpPostIn"> <wsdl:part name="theCityCode" type="s:string" /> <wsdl:part name="theUserID" type="s:string" /> </wsdl:message> <wsdl:message name="getWeatherHttpPostOut"> <wsdl:part name="Body" element="tns:ArrayOfString" /> </wsdl:message> <wsdl:portType name="WeatherWSSoap"> <wsdl:operation name="getRegionDataset"> <wsdl:input message="tns:getRegionDatasetSoapIn" /> <wsdl:output message="tns:getRegionDatasetSoapOut" /> </wsdl:operation> <wsdl:operation name="getRegionProvince"> <wsdl:input message="tns:getRegionProvinceSoapIn" /> <wsdl:output message="tns:getRegionProvinceSoapOut" /> </wsdl:operation> <wsdl:operation name="getRegionCountry"> <wsdl:input message="tns:getRegionCountrySoapIn" /> <wsdl:output message="tns:getRegionCountrySoapOut" /> </wsdl:operation> <wsdl:operation name="getSupportCityDataset"> <wsdl:input message="tns:getSupportCityDatasetSoapIn" /> <wsdl:output message="tns:getSupportCityDatasetSoapOut" /> </wsdl:operation> <wsdl:operation name="getSupportCityString"> <wsdl:input message="tns:getSupportCityStringSoapIn" /> <wsdl:output message="tns:getSupportCityStringSoapOut" /> </wsdl:operation> <wsdl:operation name="getWeather"> <wsdl:input message="tns:getWeatherSoapIn" /> <wsdl:output message="tns:getWeatherSoapOut" /> </wsdl:operation> </wsdl:portType> <wsdl:portType name="WeatherWSHttpGet"> <wsdl:operation name="getRegionDataset"> <wsdl:input message="tns:getRegionDatasetHttpGetIn" /> <wsdl:output message="tns:getRegionDatasetHttpGetOut" /> </wsdl:operation> <wsdl:operation name="getRegionProvince"> <wsdl:input message="tns:getRegionProvinceHttpGetIn" /> <wsdl:output message="tns:getRegionProvinceHttpGetOut" /> </wsdl:operation> <wsdl:operation name="getRegionCountry"> <wsdl:input message="tns:getRegionCountryHttpGetIn" /> <wsdl:output message="tns:getRegionCountryHttpGetOut" /> </wsdl:operation> <wsdl:operation name="getSupportCityDataset"> <wsdl:input message="tns:getSupportCityDatasetHttpGetIn" /> <wsdl:output message="tns:getSupportCityDatasetHttpGetOut" /> </wsdl:operation> <wsdl:operation name="getSupportCityString"> <wsdl:input message="tns:getSupportCityStringHttpGetIn" /> <wsdl:output message="tns:getSupportCityStringHttpGetOut" /> </wsdl:operation> <wsdl:operation name="getWeather"> <wsdl:input message="tns:getWeatherHttpGetIn" /> <wsdl:output message="tns:getWeatherHttpGetOut" /> </wsdl:operation> </wsdl:portType> <wsdl:portType name="WeatherWSHttpPost"> <wsdl:operation name="getRegionDataset"> <wsdl:input message="tns:getRegionDatasetHttpPostIn" /> <wsdl:output message="tns:getRegionDatasetHttpPostOut" /> </wsdl:operation> <wsdl:operation name="getRegionProvince"> <wsdl:input message="tns:getRegionProvinceHttpPostIn" /> <wsdl:output message="tns:getRegionProvinceHttpPostOut" /> </wsdl:operation> <wsdl:operation name="getRegionCountry"> <wsdl:input message="tns:getRegionCountryHttpPostIn" /> <wsdl:output message="tns:getRegionCountryHttpPostOut" /> </wsdl:operation> <wsdl:operation name="getSupportCityDataset"> <wsdl:input message="tns:getSupportCityDatasetHttpPostIn" /> <wsdl:output message="tns:getSupportCityDatasetHttpPostOut" /> </wsdl:operation> <wsdl:operation name="getSupportCityString"> <wsdl:input message="tns:getSupportCityStringHttpPostIn" /> <wsdl:output message="tns:getSupportCityStringHttpPostOut" /> </wsdl:operation> <wsdl:operation name="getWeather"> <wsdl:input message="tns:getWeatherHttpPostIn" /> <wsdl:output message="tns:getWeatherHttpPostOut" /> </wsdl:operation> </wsdl:portType> <wsdl:binding name="WeatherWSSoap" type="tns:WeatherWSSoap"> <soap:binding transport="http://schemas.xmlsoap.org/soap/http" /> <wsdl:operation name="getRegionDataset"> <soap:operation soapAction="http://WebXml.com.cn/getRegionDataset" style="document" /> <wsdl:input> <soap:body use="literal" /> </wsdl:input> <wsdl:output> <soap:body use="literal" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getRegionProvince"> <soap:operation soapAction="http://WebXml.com.cn/getRegionProvince" style="document" /> <wsdl:input> <soap:body use="literal" /> </wsdl:input> <wsdl:output> <soap:body use="literal" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getRegionCountry"> <soap:operation soapAction="http://WebXml.com.cn/getRegionCountry" style="document" /> <wsdl:input> <soap:body use="literal" /> </wsdl:input> <wsdl:output> <soap:body use="literal" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getSupportCityDataset"> <soap:operation soapAction="http://WebXml.com.cn/getSupportCityDataset" style="document" /> <wsdl:input> <soap:body use="literal" /> </wsdl:input> <wsdl:output> <soap:body use="literal" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getSupportCityString"> <soap:operation soapAction="http://WebXml.com.cn/getSupportCityString" style="document" /> <wsdl:input> <soap:body use="literal" /> </wsdl:input> <wsdl:output> <soap:body use="literal" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getWeather"> <soap:operation soapAction="http://WebXml.com.cn/getWeather" style="document" /> <wsdl:input> <soap:body use="literal" /> </wsdl:input> <wsdl:output> <soap:body use="literal" /> </wsdl:output> </wsdl:operation> </wsdl:binding> <wsdl:binding name="WeatherWSSoap12" type="tns:WeatherWSSoap"> <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" /> <wsdl:operation name="getRegionDataset"> <soap12:operation soapAction="http://WebXml.com.cn/getRegionDataset" style="document" /> <wsdl:input> <soap12:body use="literal" /> </wsdl:input> <wsdl:output> <soap12:body use="literal" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getRegionProvince"> <soap12:operation soapAction="http://WebXml.com.cn/getRegionProvince" style="document" /> <wsdl:input> <soap12:body use="literal" /> </wsdl:input> <wsdl:output> <soap12:body use="literal" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getRegionCountry"> <soap12:operation soapAction="http://WebXml.com.cn/getRegionCountry" style="document" /> <wsdl:input> <soap12:body use="literal" /> </wsdl:input> <wsdl:output> <soap12:body use="literal" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getSupportCityDataset"> <soap12:operation soapAction="http://WebXml.com.cn/getSupportCityDataset" style="document" /> <wsdl:input> <soap12:body use="literal" /> </wsdl:input> <wsdl:output> <soap12:body use="literal" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getSupportCityString"> <soap12:operation soapAction="http://WebXml.com.cn/getSupportCityString" style="document" /> <wsdl:input> <soap12:body use="literal" /> </wsdl:input> <wsdl:output> <soap12:body use="literal" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getWeather"> <soap12:operation soapAction="http://WebXml.com.cn/getWeather" style="document" /> <wsdl:input> <soap12:body use="literal" /> </wsdl:input> <wsdl:output> <soap12:body use="literal" /> </wsdl:output> </wsdl:operation> </wsdl:binding> <wsdl:binding name="WeatherWSHttpGet" type="tns:WeatherWSHttpGet"> <http:binding verb="GET" /> <wsdl:operation name="getRegionDataset"> <http:operation location="/getRegionDataset" /> <wsdl:input> <http:urlEncoded /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getRegionProvince"> <http:operation location="/getRegionProvince" /> <wsdl:input> <http:urlEncoded /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getRegionCountry"> <http:operation location="/getRegionCountry" /> <wsdl:input> <http:urlEncoded /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getSupportCityDataset"> <http:operation location="/getSupportCityDataset" /> <wsdl:input> <http:urlEncoded /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getSupportCityString"> <http:operation location="/getSupportCityString" /> <wsdl:input> <http:urlEncoded /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getWeather"> <http:operation location="/getWeather" /> <wsdl:input> <http:urlEncoded /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> </wsdl:binding> <wsdl:binding name="WeatherWSHttpPost" type="tns:WeatherWSHttpPost"> <http:binding verb="POST" /> <wsdl:operation name="getRegionDataset"> <http:operation location="/getRegionDataset" /> <wsdl:input> <mime:content type="application/x-www-form-urlencoded" /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getRegionProvince"> <http:operation location="/getRegionProvince" /> <wsdl:input> <mime:content type="application/x-www-form-urlencoded" /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getRegionCountry"> <http:operation location="/getRegionCountry" /> <wsdl:input> <mime:content type="application/x-www-form-urlencoded" /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getSupportCityDataset"> <http:operation location="/getSupportCityDataset" /> <wsdl:input> <mime:content type="application/x-www-form-urlencoded" /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getSupportCityString"> <http:operation location="/getSupportCityString" /> <wsdl:input> <mime:content type="application/x-www-form-urlencoded" /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> <wsdl:operation name="getWeather"> <http:operation location="/getWeather" /> <wsdl:input> <mime:content type="application/x-www-form-urlencoded" /> </wsdl:input> <wsdl:output> <mime:mimeXml part="Body" /> </wsdl:output> </wsdl:operation> </wsdl:binding> <wsdl:service name="WeatherWS"> <wsdl:port name="WeatherWSSoap" binding="tns:WeatherWSSoap"> <soap:address location="http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx" /> </wsdl:port> <wsdl:port name="WeatherWSSoap12" binding="tns:WeatherWSSoap12"> <soap12:address location="http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx" /> </wsdl:port> <wsdl:port name="WeatherWSHttpGet" binding="tns:WeatherWSHttpGet"> <http:address location="http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx" /> </wsdl:port> <wsdl:port name="WeatherWSHttpPost" binding="tns:WeatherWSHttpPost"> <http:address location="http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx" /> </wsdl:port> </wsdl:service> </wsdl:definitions>
1 楼
sswh
2013-06-05
AXIS2和CXF之间有什么渊源吗?还是两个完全不同的实现?
举例来说:对于 http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx?wsdl
使用JDK6 的 wsimport、或者 CXF 的wsdl2java 解析都报错。
但是axis2可以识别。
~~~~~~~~~~
AXIS2比CXF和JDK自带的WebService功能都要更加完善吗?
举例来说:对于 http://webservice.webxml.com.cn/WebServices/WeatherWS.asmx?wsdl
使用JDK6 的 wsimport、或者 CXF 的wsdl2java 解析都报错。
引用
undefined element declaration 's:schema'
但是axis2可以识别。
~~~~~~~~~~
AXIS2比CXF和JDK自带的WebService功能都要更加完善吗?
相关推荐
基于jax-ws 实现的web service client和server端的demo程序。 注:如果使用的是 myeclipse 时 server 部署到tomcat 启动的时候会报错 解决办法:找到myeclipse安装目录下的 plugins 目录里 查找 webservices-rt.jar,...
NULL 博文链接:https://yimengzhu.iteye.com/blog/1879330
jax-ws方式的webservice服务,基于xml的webservice开发,资料很全面很珍贵,大师所写的书籍,真心不贵
JAX-WS自学笔记 本人自学JAX-WS笔记和简单例子,文档标题结构如下: JAX-WS使用教程 1、JAX-WS概述 2、创建Web Service 2.1 从java开始 2.1.1 运行wsgen 2.1.2 生成的WSDL和XSD 2.1.3 目录结构 2.2 从WSDL...
亲测可用,Jax-ws所需要的JAR包,拷贝到tomcat安装路径的lib里,实现了webservice发布到tomcat,赞!
学习JAX-WSWebService开发相关文档及Myeclipse开发方法。
webService部署tomcat需要的jax-ws 的完整jar包
JAX-WS Web service 开发初步
rar中包含整个项目的源码和数据库生成脚本,采用jax-ws发布Web Service服务,支持java客户端和.Net客户端调用,数据库采用oracle10g,里面有创建数据库脚本文件createTable_Oracle10g.sql,由于Hibernate映射表中会...
The Java API for XML Web Services (JAX-WS) is a Java programming language API for creating web services, particularly SOAP services. JAX-WS is one of the Java XML programming APIs. It's a part of the ...
JAX-WS 2.2 RI 所包含的JAR包集合,包含25个JAR包,列表如下: FastInoset.jar gmbal-api-only.jar ha-api.jar javax.annotation.jar javax.mail_1.4.jar jaxb-api.jar jaxb-impl.jar jaxb-xjc.jar jaxws-api...
MyEclipse8_0中使用 JAX-WS 部署 WebService 实例 - 外衣 - 博客频道 - CSDN_NET.mht
JAX-WS方式开发和部署webservice应用,JAX-WS方式开发和部署webservice应用,JAX-WS方式开发和部署webservice应用,JAX-WS方式开发和部署webservice应用,JAX-WS方式开发和部署webservice应用
JAX-WS2.0 API
Jax-WS的简单实例 Jax-WS的简单实例
javax.xml.ws.Service 报错需要的包,亲测可以用,直接下载在ide里buildpath一下就可以,四个jar包 ,整合了其他的jar所以配置简单
jax-ws webservice完整demo,包含所有jax-ws 2.2jar包。
使用JAX-WS(JWS)发布WebService 使用myeclipse开发java的webservice的两种方式 方式一: (此方式只能作为调试,有以下bug:jdk1.6u17?以下编译器不支持以Endpoint.publish方式发布document方式的soap,必须在...
JAX-WS 2.2 RI 所包含的JAR包集合,包含25个JAR包,列表如下: FastInoset.jar gmbal-api-only.jar ha-api.jar javax.annotation.jar javax.mail_1.4.jar jaxb-api.jar jaxb-impl.jar jaxb-xjc.jar jaxws-api...
自己自学JAX-WS的心得,内含较为详细的讲解了简单的例子。文档目录如下: JAX-WS自学笔记 本人自学JAX-WS笔记和简单例子,文档标题结构如下: JAX-WS使用教程 1、JAX-WS概述 2、创建Web Service 2.1 从java...