[jboss-user] [JBossWS] - Re: Newbee Q: Returning hashmaps

mikkus do-not-reply at jboss.com
Tue Apr 29 05:54:56 EDT 2008


toString() outputs the contents of the HashMap only if the class generated is actually a HashMap, otherwise it outputs the java class instance name.

Most probably, wsconsume generated a class named HashMap, instead of using java.util.HashMap. This class is not actually a hashmap but a representation of the web service return data. Most probably, you'll need to convert that data to an actual hashmap.

I notice you commented out the cast to java.util.HashMap, probably you got a ClassCastException here? Seeing the class generated by wsconsume and related wsdl would help.

Your web.xml file should not be the problem. It just exposes the webservice, and since you're able to invoke it, it is doing its job.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4147462#4147462

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4147462



More information about the jboss-user mailing list