Class LocalDateAdaptor

java.lang.Object
com.walkfares.calendar.adaptor.LocalDateAdaptor
All Implemented Interfaces:
com.google.gson.JsonDeserializer<LocalDate>, com.google.gson.JsonSerializer<LocalDate>

public class LocalDateAdaptor
extends Object
implements com.google.gson.JsonSerializer<LocalDate>, com.google.gson.JsonDeserializer<LocalDate>
  • Constructor Details

  • Method Details

    • serialize

      public com.google.gson.JsonElement serialize​(LocalDate date, Type typeOfSrc, com.google.gson.JsonSerializationContext context)
      Specified by:
      serialize in interface com.google.gson.JsonSerializer<LocalDate>
    • deserialize

      public LocalDate deserialize​(com.google.gson.JsonElement json, Type typeOfT, com.google.gson.JsonDeserializationContext context) throws com.google.gson.JsonParseException
      Specified by:
      deserialize in interface com.google.gson.JsonDeserializer<LocalDate>
      Throws:
      com.google.gson.JsonParseException