commit | 47107914acbad70ff4db1664d3664ccc994315af | [log] [tgz] |
---|---|---|
author | Andrew Flynn <flynn@google.com> | Tue May 28 16:07:32 2013 -0700 |
committer | Andrew Flynn <flynn@google.com> | Tue Jun 04 13:26:58 2013 -0700 |
tree | ef66f1740d261023f551b45593dbe44622a31705 | |
parent | d29f87c79f34ecd6b7889cc49ca9e9d90c413634 [diff] |
Add toString() method to MessageNano. - All of the real work for printing the proto is actually done in MessageNanoPrinter. - Uses reflection to find proto-defined fields and prints those. - Prints all fields, even defaults and nulls. - Also added a simple test to make sure it handles all proto types well. Tried not to make the test too brittle (but hey it's testing a toString() so how flexible can it be) Change-Id: I3e360ef8b0561041e010c1f3445ec45ecdcd2559