public abstract static class AbstractTypedConfig.AbstractGsonAdapter<T extends AbstractTypedConfig>
extends java.lang.Object
implements com.google.gson.JsonDeserializer<T>, com.google.gson.JsonSerializer<T>
Constructor and Description |
---|
AbstractGsonAdapter() |
Modifier and Type | Method and Description |
---|---|
protected abstract T |
create(java.lang.String type,
com.google.gson.JsonElement config) |
T |
deserialize(com.google.gson.JsonElement json,
java.lang.reflect.Type typeOfT,
com.google.gson.JsonDeserializationContext context) |
com.google.gson.JsonElement |
serialize(T src,
java.lang.reflect.Type typeOfSrc,
com.google.gson.JsonSerializationContext context) |
@Nonnull protected abstract T create(@Nonnull java.lang.String type, @Nonnull com.google.gson.JsonElement config)
public T deserialize(com.google.gson.JsonElement json, java.lang.reflect.Type typeOfT, com.google.gson.JsonDeserializationContext context)
deserialize
in interface com.google.gson.JsonDeserializer<T extends AbstractTypedConfig>
public com.google.gson.JsonElement serialize(T src, java.lang.reflect.Type typeOfSrc, com.google.gson.JsonSerializationContext context)
serialize
in interface com.google.gson.JsonSerializer<T extends AbstractTypedConfig>