Hello,

I define a Java Map object, and set some key-value in this map. For example

public class Test{
     @Put
     @Produces("application/json")
     public Map getJson(){
           Map map = new HashMap();
           map.put("success", "ok");
           map.put("failure", "fail");
           return map;
     }
}


The return json string is :
{ entry:
  {
     [key:success, value:ok],
     [key:failure, value:fail] 
  }
}

But I want to get :
{
 [
   success:ok, 
   failure: fail
 ]
}

Please give me a good solution for it. Thanks

-ppju
-- 
View this message in context: 
http://cxf.547215.n5.nabble.com/Cannot-get-the-right-json-from-the-Map-object-tp2266636p2266636.html
Sent from the cxf-user mailing list archive at Nabble.com.

Reply via email to