[wise-users] "out" parameter in web service

Yanguang Chen chygr1234 at gmail.com
Sun Dec 12 21:28:55 EST 2010


Hello everyone,
Wise 1.1 is really great, i like the easy way to use it. But recently i
encounter a problem.
When i tried to invoke a simple web service with "out" parameter, "argument
type mismatch" exceptions were thrown. I read the API carefully and took a
close look at the source code (to be more precise,
"src\core\src\test\java\org\jboss\wise\core\client\impl\reflection\WSMethodImplTest.java"),
then found wise did support the "out" parameter, am i right?
Here is a code snippet:

    val clientBuilder = WSDynamicClientFactory.getJAXWSClientBuilder();
    val client =
clientBuilder.tmpDir("clienttmp").verbose(true).keepSource(true)
    .wsdlURL("http://localhost:7777/info?wsdl").build();
    val method = client.getWSMethod("InformationService", "InformationPort",
"getInfo");

    val requestMap = new HashMap[String, Object]

    requestMap.put("arg0", "test".asInstanceOf[Object]);
    requestMap.put("arg1", Integer.valueOf(3));
    requestMap.put("arg2", Integer.valueOf(0));

    val result = method.invoke(requestMap, null);
    System.out.println(result.getMapRequestAndResult(null, null));
    client.close();

It's written in Scala. Since it's very simple , i don't think there is a
need to explain it.
The logfile and sample server-side web service code are in the attachment.
Can anybody help me?
Thanks in advance.


Best Regards,
Yanguang Chen
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/wise-users/attachments/20101213/5fd2c7d2/attachment.html 


More information about the wise-users mailing list