This is basically a JAXB bug
https://jaxb.dev.java.net/issues/show_bug.cgi?id=268.
The workaround you can use it to wrap your map into another class. This class
has to be annotated with @XmlAccessorType(XmlAccessType.FIELD) since the bug
prevents you from adding @XmlElement to your map field.
| @XmlAccessorType(XmlAccessType.FIELD)
| public class MyMap {
|
| protected HashMap<String,String> realMap;
|
| public HashMap<String,String> getRealMap() {
| if (realMap==null) {
| realMap = new HashMap<String,String>();
| }
| return realMap;
| }
| }
|
| ...
|
| @WebMethod
| public MyMap getHashMap( String key, String value) {
| ...
| }
|
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4108835#4108835
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4108835
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user