public class GsonDateTypeAdapter extends com.google.gson.TypeAdapter<Date>
Date
objects with GSON. This code is copied from
DateTypeAdapter
and modified slightly to add the Java9+ data time format when
running in Java8 or earlier.Constructor and Description |
---|
GsonDateTypeAdapter() |
Modifier and Type | Method and Description |
---|---|
Date |
read(com.google.gson.stream.JsonReader in) |
void |
write(com.google.gson.stream.JsonWriter out,
Date value) |
public Date read(com.google.gson.stream.JsonReader in) throws IOException
read
in class com.google.gson.TypeAdapter<Date>
IOException
public void write(com.google.gson.stream.JsonWriter out, Date value) throws IOException
write
in class com.google.gson.TypeAdapter<Date>
IOException
Copyright © 2019 XIMA MEDIA GmbH. All rights reserved.