请帮助我!
在我的代码中,我使用ksoap连接到SOAP服务:
SoapObject request = new SoapObject(NAMESPACE, METHOD_NAME);
request.addProperty("user", user);
request.addProperty("ident",hashid);
Log.e("Request:", request.toString());
SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11);
envelope.dotNet = true;
envelope.setOutputSoapObject(request);
HttpTransportSE transportSE = new HttpTransportSE(URL);
transportSE.debug = true;
Object response = new Object();
try
{
transportSE.call(SOAP_ACTION, envelope);
Log.e ("Request dump", transportSE.requestDump);
Log.e ("Response dump", transportSE.responseDump);
//SoapObject resultSoapObject = (SoapObject) envelope.bodyIn;
response = envelope.getResponse();
System.out.println("Response:"+ response.toString());
} catch (HttpResponseException e) {
e.printStackTrace();
} catch (XmlPullParserException e) {
e.printStackTrace();
} catch (IOException e) {
System.out.println("Error"+e);
e.printStackTrace();
}
return response.toString();
运行此代码后,我在日志中遇到下一个错误,并且我不理解我在做什么错事
E/Request dump: <v:Envelope xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns:d="http://www.w3.org/2001/XMLSchema" xmlns:c="http://schemas.xmlsoap.org/soap/encoding/" xmlns:v="http://schemas.xmlsoap.org/soap/envelope/"><v:Header /><v:Body><login_test xmlns="http://appServer.ua.org.blackmerlin/" id="o0" c:root="1"><user i:type="d:string">10200</user><ident i:type="d:string">f2168b32d025c9847cf87e5518baafb6</ident></login_test></v:Body></v:Envelope>
E/Response dump: <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><S:Fault xmlns:ns4="http://www.w3.org/2003/05/soap-envelope"><faultcode>S:Server</faultcode><faultstring>javax.ejb.EJBException</faultstring></S:Fault></S:Body></S:Envelope>
I/System.out: ErrorSoapFault - faultcode: 'S:Server' faultstring: 'javax.ejb.EJBException' faultactor: 'null' detail: null
W/System.err: SoapFault - faultcode: 'S:Server' faultstring: 'javax.ejb.EJBException' faultactor: 'null' detail: null
at org.ksoap2.serialization.SoapSerializationEnvelope.parseBody(SoapSerializationEnvelope.java:136)
at org.ksoap2.SoapEnvelope.parse(SoapEnvelope.java:140)
at org.ksoap2.transport.Transport.parseResponse(Transport.java:129)
at org.ksoap2.transport.HttpTransportSE.parseResponse(HttpTransportSE.java:304)
at org.ksoap2.transport.HttpTransportSE.call(HttpTransportSE.java:276)
at org.ksoap2.transport.HttpTransportSE.call(HttpTransportSE.java:118)
W/System.err: at org.ksoap2.transport.HttpTransportSE.call(HttpTransportSE.java:113)
at com.example.yy.soapclient.UpdateTask.doInBackground(MainActivity.java:76)
at com.example.yy.soapclient.UpdateTask.doInBackground(MainActivity.java:35)
at android.os.AsyncTask$2.call(AsyncTask.java:288)
at java.util.concurrent.FutureTask.run(FutureTask.java:237)
at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:231)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)
at java.lang.Thread.run(Thread.java:841)
D/EGL_emulation: eglMakeCurrent: 0xb86bb110: ver 2 0
E/EGL_emulation: tid 2989: eglSurfaceAttrib(1199): error 0x3009 (EGL_BAD_MATCH)
帮助我弄清楚我的错误在哪里以及我在做什么错