Class ConditionalTypeAdapter
java.lang.Object
com.google.gson.TypeAdapter<Conditional>
dev.foxikle.customnpcs.actions.conditions.ConditionalTypeAdapter
The object allowing Gson to parse conditional objects
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionread
(com.google.gson.stream.JsonReader in) void
write
(com.google.gson.stream.JsonWriter out, Conditional conditional) Methods inherited from class com.google.gson.TypeAdapter
fromJson, fromJson, fromJsonTree, nullSafe, toJson, toJson, toJsonTree
-
Constructor Details
-
ConditionalTypeAdapter
public ConditionalTypeAdapter()
-
-
Method Details
-
write
public void write(com.google.gson.stream.JsonWriter out, Conditional conditional) throws IOException - Specified by:
write
in classcom.google.gson.TypeAdapter<Conditional>
- Parameters:
out
- the data write out toconditional
- the Java object to write. May be null.- Throws:
IOException
- if an exception occours
-
read
- Specified by:
read
in classcom.google.gson.TypeAdapter<Conditional>
- Parameters:
in
- the data to parse- Returns:
- the deserialized Conditional
- Throws:
IOException
- if an error occours reading
-