我被困試圖找出如何啓動與EodData.comEodData WSDL的Java連接
的WSDL地址是
http://ws.eoddata.com/data.asmx?wsdl
我使用CXF來創建一個客戶端連接一個WSDL連接:
QName qname = new QName("http://ws.eoddata.com/Data", "Data");
Data data = new Data(new URL("http://ws.eoddata.com/data.asmx?wsdl"), qname);
DataHttpGet dataGet = data.getDataHttpGet();
dataGet.login("xxx", "ppp");
和我
Caused by: org.apache.cxf.interceptor.Fault: Unmarshalling Error: unexpected element (uri:"http://schemas.xmlsoap.org/soap/envelope/", local:"Header"). Expected elements are <{http://ws.eoddata.com/Data}LoginResult>
不知道我應該如何啓動連接?
什麼是@WebServiceClient看起來像Data類? – 2010-07-28 16:58:36