Class DurationConverter

java.lang.Object
org.mbari.vars.vampiresquid.sdk.r1.etc.gson.DurationConverter
All Implemented Interfaces:
com.google.gson.JsonDeserializer<Duration>, com.google.gson.JsonSerializer<Duration>

public class DurationConverter extends Object implements com.google.gson.JsonSerializer<Duration>, com.google.gson.JsonDeserializer<Duration>
Since:
2016-07-11T15:57:00
Author:
Brian Schlining
  • Constructor Details

    • DurationConverter

      public DurationConverter()
  • Method Details

    • deserialize

      public Duration 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<Duration>
      Throws:
      com.google.gson.JsonParseException
    • serialize

      public com.google.gson.JsonElement serialize(Duration src, Type typeOfSrc, com.google.gson.JsonSerializationContext context)
      Specified by:
      serialize in interface com.google.gson.JsonSerializer<Duration>