wsdl问题
高手赐教:这是别的服务器发布的一个wsdl的内容如下:
<?xml version="1.0" encoding="UTF-8" ?>
- <wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsrt="http://schemas.xmlsoap.org/ws/2006/08/resourceTransfer" xmlns:wsa="http://www.w3.org/2005/08/addressing" xmlns:wsam="http://www.w3.org/2007/05/addressing/metadata" xmlns:wst="http://schemas.xmlsoap.org/ws/2004/09/transfer" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" targetNamespace="http://schemas.xmlsoap.org/ws/2006/08/resourceTransfer">
<wsdl:import namespace="http://schemas.xmlsoap.org/ws/2006/08/resourceTransfer" location="ResourceService.wsdl" />
<wsdl:import namespace="http://schemas.xmlsoap.org/ws/2004/09/transfer" location="transfer.wsdl" />
- <wsdl:types>
- <xs:schema>
<xs:import namespace="http://www.energiened.nl/Content/Publications/dsmr/P32" schemaLocation="www.energiened.nl/Content/Publications/dsmr/P32/p32Schema.xsd" />
</xs:schema>
</wsdl:types>
- <wsdl:binding name="ResourceInte易做图ceBinding" type="wsrt:ResourceInte易做图ce">
<soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document" />
- <wsdl:operation name="Get">
<soap:operation soapAction="Get_action" />
- <wsdl:input>
<soap:body use="literal" />
</wsdl:input>
- <wsdl:output>
<soap:body use="literal" />
</wsdl:output>
</wsdl:operation>
- <wsdl:operation name="Put">
<soap:operation soapAction="Put_action" />
- <wsdl:input>
<soap:body use="literal" />
</wsdl:input>
- <wsdl:output>
<soap:body use="literal" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
+ <wsdl:binding name="ResourceBinding" type="wst:Resource">
<soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document" />
- <wsdl:operation name="Get">
<soap:operation soapAction="Get_action" />
- <wsdl:input>
<soap:body use="literal" />
</wsdl:input>
- <wsdl:output>
<soap:body use="literal" />
</wsdl:output>
</wsdl:operation>
- <wsdl:operation name="Put">
<soap:operation soapAction="Put_action" />
- <wsdl:input>
<soap:body use="literal" />
</wsdl:input>
- <wsdl:output>
<soap:body use="literal" />
</wsdl:output>
</wsdl:operation>
- <wsdl:operation name="Delete">
<soap:operation soapAction="Delete_action" />
- <wsdl:input>
<soap:body use="literal" />
</wsdl:input>
- <wsdl:output>
<soap:body use="literal" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
- <wsdl:service name="ResourceInte易做图ceService">
- <wsdl:port name="ResourceInte易做图cePort" binding="wsrt:ResourceInte易做图ceBinding">
<soap:address location="http://192.168.228.203:7070/ResourceInte易做图ceService?wsdl" />
</wsdl:port>
</wsdl:service>
+ <wsdl:service name="ResourceService">
- <wsdl:port name="ResourcePort" binding="wsrt:ResourceBinding">
<soap:address location="http://192.168.228.203:7070/ResourceService?wsdl" />
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
请问我如何调用这个wsdl,这个wsdl没有portType之类的函数这个接口,只有binding的内容,我使用的java的Axis2框架调用,需要传一个XML给这个Create函数,但是这个xml以什么内容传进去不是很清楚,刚学webservice,请高手帮忙看看:
我下的客户端代码:
//第一步
RPCServiceClient serviceClient = new RPCServiceClient();
Options options = serviceClient.getOptions();
//第二步
EndpointReference targetEPR= new EndpointReference( "http://192.168.228.203:7070/ResourceFactoryInte易做图ceService");
options.setTo(targetEPR);
//第三步
Object[] opAddEntryArgs= new Object[] {a}; //a是要传入的字符串xml
//第四步
Class[] classes = new Class[] {String.class};
//第五步
QName opAddEntry = new QName("http://schemas.xmlsoap.org/ws/2006/08/resourceTransfer","Create");
//第六步
System.out.println(serviceClient.invokeBlocking(opAddEntry, opAddEntryArgs,classes)[0]);
补充:Java , Java相关