Class GsonJavaTimeAdapter.ZoneIdHierarchyAdapter

java.lang.Object
com.google.gson.TypeAdapter<ZoneId>
de.xima.fc.helper.GsonJavaTimeAdapter.ZoneIdHierarchyAdapter
Enclosing class:
GsonJavaTimeAdapter

public static class GsonJavaTimeAdapter.ZoneIdHierarchyAdapter extends com.google.gson.TypeAdapter<ZoneId>
Type adapter for ZoneId and its subclasses. Serialized representation is a JSON object with the id property for ZoneRegion; or the totalSeconds property for ZoneOffset.
Since:
7.0.0
Author:
XIMA MEDIA GmbH
  • Constructor Details

    • ZoneIdHierarchyAdapter

      public ZoneIdHierarchyAdapter()
  • Method Details

    • read

      public ZoneId read(com.google.gson.stream.JsonReader in) throws IOException
      Specified by:
      read in class com.google.gson.TypeAdapter<ZoneId>
      Throws:
      IOException
    • write

      public void write(com.google.gson.stream.JsonWriter out, ZoneId value) throws IOException
      Specified by:
      write in class com.google.gson.TypeAdapter<ZoneId>
      Throws:
      IOException