【发布时间】:2011-07-27 08:02:18
【问题描述】:
我正在尝试使用一个返回 Java 哈希映射的 Web 服务,下面是它的代码
String endpoint =
"http://localhost:8080/eCWServices/StructSpeech/StructSpeech";
Service service = new Service();
Call call = (Call) service.createCall();
call.setTargetEndpointAddress(new java.net.URL(endpoint));
call.setOperationName(new QName("http://ejb.ecw.com/", "parseNotes"));
call.addParameter("notes", org.apache.axis.Constants.XSD_STRING, ParameterMode.IN);
call.addParameter("apuId", org.apache.axis.Constants.XSD_STRING, ParameterMode.IN);
call.addParameter("providerId", org.apache.axis.Constants.XSD_STRING, ParameterMode.IN);
call.setReturnType(XMLType.SOAP_MAP);
HashMap ret = (HashMap) call.invoke(new Object[]{"","",""});
System.out.println("Sent 'Hello!', got '" + ret + "'");
返回的 HashMap 始终为空,我认为该轴不支持它。谁能给我指点,我可以在哪里找到如何在 jdk 1.4 中使用返回哈希图的服务?
【问题讨论】:
标签: java web-services axis