You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Dapeng Wang <da...@db.com> on 2003/01/24 11:37:09 UTC

Method with return type void.

Hi,

I have a very simple method called
public void hello(String name);

When I tried to invoke this method, everything seems fine when I just use
call.invoke(new Object[] {"World"});

But if I call
call.addParameter("name", Constants.XSD_STRING, ParameterMode.IN);
before the invocation, I am forced to call setReturnType. But what QName should I use for void.

call.setReturnClass(Void.TYPE) helps in this case, but I would like to know whether there is another possibility to not use setReturnClass.

Furthermore, when do I have to call addParameter and setReturnType? Is it just a good programming style or does AXIS need this meta information for some situations?

thanks
Dapeng Wang


--

Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser Mail ist nicht gestattet.

This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden.