简体   繁体   English

java-Web服务客户端看不到方法参数

[英]java - web service client does not see the method arguments

I create a bottom up web service on axis2 1.4.1 and tomcat 6.20 with a simple method such as 我使用简单的方法在axis2 1.4.1和tomcat 6.20上创建了一个自底向上的Web服务。

int helloWorld(int op1, int op2) {
   return op1 + op2;
}

and then I edit the services.xml file and include this method like this: 然后我编辑services.xml文件,并包含如下所示的方法:

<operation name="helloWorld">
     <messageReceiver class="org.apache.axis2.rpc.receivers.RPCMessageReceiver" /> </operation>

Then I create a web service client on Eclipse IDE. 然后,我在Eclipse IDE上创建一个Web服务客户端。 THe problem is that even though I can see the method on the client, the method appears to accept no arguments. 问题是,即使我可以在客户端上看到该方法,该方法似乎也不接受任何参数。

How should I change the configuration to solve this problem? 如何更改配置以解决此问题? Thanks a lot, 非常感谢,

Axis2通过反射进行工作,因此我怀疑您需要将该方法公开。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM