Skip to content

Instantly share code, notes, and snippets.

@samuelstein
Created October 23, 2018 09:40
Embed
What would you like to do?
Deserialize generic list with gson
Type listType = new TypeToken<ArrayList<YourClass>>(){}.getType();
List<YourClass> yourClassList = new Gson().fromJson(jsonArray, listType);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment