我用RAD创建了一个WEBSERVICE 。
CLIENT使用PHP nusoapClient的方式调用,方法如下:
$page=5;
$pageSize=50;
$param = array('page'=>$page,'pagesize'=>$pageSize);
$response = $client->call('getBills',array('parameters' => $param));
可以进入webservice 方法,但是不知道该如何接收参数。
为 webservice方法创建带参数的接口方法 public Bill[] getBills(Map map) throws Exception{ ...}
但是无法创建参数为Map 类型的方法。
在create webservice 时,有以下提示:
com.sun.xml.internal.bind.v2.runtime.IllegalAnnotationsException: 2 counts of IllegalAnnotationExceptions
java.util.Map is an interface, and JAXB can't handle interfaces.
this problem is related to the following location:
at java.util.Map
at private java.util.Map com.ibm.its.finance.delegate.jaxws.GetBills.arg0
at com.ibm.its.finance.delegate.jaxws.GetBills
java.util.Map does not have a no-arg default constructor.
this problem is related to the following location:
at java.util.Map。
不知道说明白没有,有疑问我再补充。
收起