Closed GoogleCodeExporter closed 9 years ago
The fundamental problem is that you aren't supplying GSON with enough type
information and so it has to infer the type from the value. You can work-around
this by providing the type in your call to toJson():
String json = gson.toJson(jsonData, new TypeToken<Map<String, List<String>>>() {}.getType()));
We still have a problem where GSON never serializes anonymous classes, which is
an unfortunate policy in this instance.
Original comment by limpbizkit
on 1 Oct 2011 at 4:40
Original comment by limpbizkit
on 2 Oct 2011 at 3:38
Issue 370 has been merged into this issue.
Original comment by limpbizkit
on 19 Oct 2011 at 4:30
Original issue reported on code.google.com by
neyas...@gmail.com
on 13 Jul 2011 at 9:39