Counterintuitively, despite this method taking only a 'date style' Gson will use a
format which includes both date and time, with the 'time style' being the last value set by
GsonBuilder.setDateFormat(int, int). Therefore prefer using GsonBuilder.setDateFormat(int, int)
and explicitly provide the desired 'time style'.
Please use JsonReader.setStrictness(Strictness) instead.
JsonReader.setLenient(true) should be replaced by
JsonReader.setStrictness(Strictness.LENIENT) and JsonReader.setLenient(false)
should be replaced by JsonReader.setStrictness(Strictness.LEGACY_STRICT).
However, if you used setLenient(false) before, you might prefer Strictness.STRICT now instead.
Please use JsonWriter.setStrictness(Strictness) instead.
JsonWriter.setLenient(true) should be replaced by
JsonWriter.setStrictness(Strictness.LENIENT) and JsonWriter.setLenient(false)
should be replaced by JsonWriter.setStrictness(Strictness.LEGACY_STRICT).
However, if you used setLenient(false) before, you might prefer Strictness.STRICT now instead.
Creating custom JsonElement subclasses is highly discouraged and can lead
to undefined behavior.
This constructor is only kept for backward compatibility.