2008-10-09 47 views
1

我有一個用Delphi構建的Web服務器,我試圖通過Eclipse嚮導創建一個Web服務客戶端來使用Java上的Web服務(我正在使用Eclipse IDE)。 Web服務資源管理器可以識別WSDL文件,但在嘗試創建客戶端時,嚮導提示存在「意外屬性」,並且不會創建任何文件。將Delphi Web服務導入到Java

這是我的wsdl文件(我的Delphi Web服務器發佈的文件)。

<?xml version="1.0" encoding="UTF-8"?> 
<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xs="http://www.w3.org/2001/XMLSchema" name="ITSOAPWebServiceservice" targetNamespace="http://tempuri.org/" xmlns:tns="http://tempuri.org/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"> 
    <message name="WebMethod0Request"> 
    <part name="Document" type="xs:string"/> 
    </message> 
    <message name="WebMethod0Response"> 
    <part name="return" type="xs:boolean"/> 
    </message> 
    <portType name="ITSOAPWebService"> 
    <operation name="WebMethod"> 
     <input message="tns:WebMethod0Request"/> 
     <output message="tns:WebMethod0Response"/> 
    </operation> 
    </portType> 
    <binding name="ITSOAPWebServicebinding" type="tns:ITSOAPWebService"> 
    <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> 
    <operation name="WebMethod"> 
     <soap:operation soapAction="urn:TWebServiceIntf1-ITSOAPWebService#WebMethod" style="rpc"/> 
     <input message="tns:WebMethod0Request"> 
     <soap:body use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:TWebServiceIntf1-ITSOAPWebService"/> 
     </input> 
     <output message="tns:WebMethod0Response"> 
     <soap:body use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:TWebServiceIntf1-ITSOAPWebService"/> 
     </output> 
    </operation> 
    </binding> 
    <service name="ITSOAPWebServiceservice"> 
    <port name="ITSOAPWebServicePort" binding="tns:ITSOAPWebServicebinding"> 
     <soap:address location="http://localhost:1024/soap/ITSOAPWebService"/> 
    </port> 
    </service> 
</definitions> 

現在,Eclipse中說, 「消息」 屬性在兩個:

definicions.binding.operation.input 
definitions.binding.operation.output 

是意想不到的。我知道這是多餘的,因爲這些已經定義在

definitions.portType.operation.input 
definitions.portType.operation.output 

但我仍然無法導入網絡服務。

我的Java應用程序將在JBoss 4.2服務器上運行,但我認爲將該客戶端創建爲Java Utility Project會更容易(因爲它只創建一個項目而不是兩個)。

那麼,有關如何讓Eclipse忽略這些屬性或Delphi不發佈它們的想法?

回答