JsonSerialization { public T fromInstance(T instance) throws IOException { return fromJson(toJson(instance)); } JsonSerialization(Class<T> classType,
      boolean failOnUnknownProperties, boolean pretty); static ObjectWriter writer(); static ObjectReader mapReader(); String getName(); ObjectMapper getMapper(); @SuppressWarnings("unchecked") synchronized T fromJson(String json); synchronized T fromJsonStream(InputStream stream); @SuppressWarnings("unchecked") synchronized T load(File jsonFile); void save(File file, T instance); @SuppressWarnings({"IOResourceOpenedButNotSafelyClosed"}) synchronized T fromResource(String resource); T fromInstance(T instance); T load(FileSystem fs, Path path); void save(FileSystem fs, Path path, T instance,
      boolean overwrite); byte[] toBytes(T instance); T fromBytes(byte[] bytes); synchronized String toJson(T instance); String toString(T instance);  }
@Test public void testCloneViaJson() throws Throwable { KeyVal unmarshalled = serDeser.fromInstance(source); assertEquals(source, unmarshalled); }