JSONObject jsonObj = new JSONObject("string");
jsonObj.toString();
"employees":[{"firstname":"stack","lastname":"overflow"}, {"firstname":"Happy","lastname":"Coding"}]
我如何可以追加:追加JSON数组的JSONObject
{"firstname":"Gloomy","lastname":"Sunday"}
以上JSON对象
我想
"employees":[{"firstname":"stack","lastname":"overflow"}, {"firstname":"Happy","lastname":"Coding"}, {"firstname":"Gloomy","lastname":"Sunday"}]
upon jsonObj.toString();
你肯定拳头代码示例产生于它的结束写入字符串?数据从哪里来? –