解決策は下記の通り。なお、JSONのアクセスにはgsonを利用してます。
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
JsonObject filesJsonObject = jo.getAsJsonObject("files"); | |
Set<Map.Entry<String, JsonElement>> filesJsonObjectEntrySet = filesJsonObject.entrySet(); | |
for (Map.Entry<String, JsonElement> es : filesJsonObjectEntrySet) { | |
JsonObject joIn = es.getValue().getAsJsonObject(); | |
String filename = joIn.getString("filename"); | |
String language =joIn.getString("language"); | |
String rawUrl=joIn.getString("raw_url"); | |
String size=joIn.getString("size"); | |
String type=joIn.getString("type"); | |
} |
0 件のコメント:
コメントを投稿