How to convert HashMap to json Array in android?

后端 未结 5 532
陌清茗
陌清茗 2020-12-03 03:20

I want to convert HashMap to json array my code is as follow:

Map map = new HashMap();

map.put(         


        
5条回答
  •  旧时难觅i
    2020-12-03 03:47

    This is the Simplest Method.

    Just use

    JSONArray jarray = new JSONArray(hashmapobject.toString);
    

提交回复
热议问题