Closed GoogleCodeExporter closed 9 years ago
Yes, by default, Gson uses compact formatting, eliminating all white-space so it
should never write a new line.
Original comment by inder123
on 15 Aug 2008 at 6:10
Closing the bug since this was a question, not an issue. The best place to post
such
questions is the Google group for Gson,
http://groups.google.com/group/google-gson
Original comment by inder123
on 15 Aug 2008 at 6:12
Okay, but I think there is an issue: it's not documented that toJson() will
return a
String in compact formatting. Also, I don't think there's a formal definition
of
what compact formatting means.
Original comment by bslesinsky
on 15 Aug 2008 at 4:01
That is a good point, and we need to explain all the default settings used by
Gson. I
have added it in r157 to the javadoc for the default constructor of Gson().
Original comment by inder123
on 15 Aug 2008 at 7:55
Original issue reported on code.google.com by
bslesinsky
on 15 Aug 2008 at 3:39