@Test public void write() throws IOException { final JsonWriter writer = mock(JsonWriter.class); this.typeAdapter.write(writer, TimeUnit.SECONDS); verify(writer).value("seconds"); }
@Override public void write(final JsonWriter out, final TimeUnit value) throws IOException { out.value(value.toString().toLowerCase(Locale.US)); }
TimeUnitTypeAdapter extends TypeAdapter<TimeUnit> { @Override public void write(final JsonWriter out, final TimeUnit value) throws IOException { out.value(value.toString().toLowerCase(Locale.US)); } }
TimeUnitTypeAdapter extends TypeAdapter<TimeUnit> { @Override public void write(final JsonWriter out, final TimeUnit value) throws IOException { out.value(value.toString().toLowerCase(Locale.US)); }  }
TimeUnitTypeAdapter extends TypeAdapter<TimeUnit> { @Override public void write(final JsonWriter out, final TimeUnit value) throws IOException { out.value(value.toString().toLowerCase(Locale.US)); }  @Override void write(final JsonWriter out, final TimeUnit value); @Override TimeUnit read(final JsonReader in); }
TimeUnitTypeAdapter extends TypeAdapter<TimeUnit> { @Override public void write(final JsonWriter out, final TimeUnit value) throws IOException { out.value(value.toString().toLowerCase(Locale.US)); }  @Override void write(final JsonWriter out, final TimeUnit value); @Override TimeUnit read(final JsonReader in);  }