org.plovr
Class CustomPassConfig.CustomPassConfigDeserializer
java.lang.Object
org.plovr.CustomPassConfig.CustomPassConfigDeserializer
- All Implemented Interfaces:
- JsonDeserializer<CustomPassConfig>
- Enclosing class:
- CustomPassConfig
public static class CustomPassConfig.CustomPassConfigDeserializer
- extends Object
- implements JsonDeserializer<CustomPassConfig>
Unfortunately, CustomPassConfig
needs a custom deserializer because
"class" is a Java keyword, so having a getClass() setter that returns a
String is problematic. All plovr options are hyphenated rather than
camel cased, so they do not work out of the box with Gson deserialization.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CustomPassConfig.CustomPassConfigDeserializer
public CustomPassConfig.CustomPassConfigDeserializer()
deserialize
public CustomPassConfig deserialize(JsonElement json,
Type typeOfT,
JsonDeserializationContext context)
throws JsonParseException
- Specified by:
deserialize
in interface JsonDeserializer<CustomPassConfig>
- Throws:
JsonParseException