@Test public void canWrite() throws Exception { TestMe test = new TestMe("foo", 42, new TestMe("bar", 666, null)); String json = om.writeValue(test); JSONAssert.assertEquals( "{\"text\":\"foo\",\"nmbr\":42,\"another\":{\"text\":\"bar\",\"nmbr\":666}}" , json , true ); }
@Override public String writeValue(Object value) { return om.toJson(value); }
GsonObjectMapper implements ObjectMapper { @Override public String writeValue(Object value) { return om.toJson(value); } }
GsonObjectMapper implements ObjectMapper { @Override public String writeValue(Object value) { return om.toJson(value); } GsonObjectMapper();  GsonObjectMapper(Gson om); }
GsonObjectMapper implements ObjectMapper { @Override public String writeValue(Object value) { return om.toJson(value); } GsonObjectMapper();  GsonObjectMapper(Gson om); @Override T readValue(String value, Class<T> valueType); @Override T readValue(String value, GenericType<T> genericType); @Override String writeValue(Object value); }
GsonObjectMapper implements ObjectMapper { @Override public String writeValue(Object value) { return om.toJson(value); } GsonObjectMapper();  GsonObjectMapper(Gson om); @Override T readValue(String value, Class<T> valueType); @Override T readValue(String value, GenericType<T> genericType); @Override String writeValue(Object value);  }