java - Convert JsonObject to String -


{     "data":      {         "map":         {             "allownestedvalues": true,             "create": "2012-12-11 15:16:13",             "title": "test201212110004",             "transitions": []         }     },     "msg": "success",     "code": "0" } 

above jsonobject, data jsonobject.

how convert string "msg":"success" know, can't directly add double quotes outside data's value.

@hsz have inbuild method convert jsonobject string. why don't use that.

 jsonobject json = new jsonobject();    json.tostring(); 

Comments