Something like this:
JSONObject songs= json.getJSONObject("songs");
Iterator x = songs.keys();
JSONArray jsonArray = new JSONArray();
while (x.hasNext()){
String key = (String) x.next();
jsonArray.put(songs.get(key));
}
More Related Contents:
- How to convert jsonString to JSONObject in Java
- JSON Array iteration in Android/Java
- how to parse JSONArray in android
- Difference between JSONObject and JSONArray
- How to Parse JSON Array with Gson
- Array of JSON Object to Java POJO
- Accessing members of items in a JSONArray with Java
- How to create correct JSONArray in Java using JSONObject
- How to parse JSON Array (Not Json Object) in Android
- Using GSON to parse a JSON array
- Add JsonArray to JsonObject
- Issue with parsing the content from JSON file with Jackson & message- JsonMappingException -Cannot deserialize as out of START_ARRAY token
- Creating nested JSON object for the following structure in Java using JSONObject? [closed]
- How do I remove a specific element from a JSONArray?
- How to access nested elements of json object using getJSONArray method
- How to convert JSONArray to List with Gson?
- How to convert HashMap to json Array in android?
- How can I turn a JSONArray into a JSONObject?
- How to write an array to allocate space for 5 things [closed]
- In java, is there anyway to go from a array of objects that got returned to the number of objects in the array? [closed]
- How to upload a file and JSON data in Postman?
- byte[] to file in Java
- length and length() in Java
- POST request via RestTemplate in JSON
- Is it ok to save a JSON array in SharedPreferences?
- What’s the best way to get a Class object for an array type?
- Java Sorting: sort an array of objects by property, object not allowed to use Comparable
- Java Modifying Elements in a foreach
- How to annotate enum fields for deserialization using Jackson json
- Jackson deserialize based on type