public final class EnumTypeAnnotationTypeAdapter extends com.google.gson.TypeAdapter<EnumAnnotation>
TypeAdapter implementation to be able to serialize EnumAnnotation instances. This TypeAnnotation
requires a special TypeAdapter due that Enum can be of an generic type.
To not loose the Type information, this TypeAdapter serializes the generic type of the Enum to be able to create
the same instance at deserialization time.
| Constructor and Description |
|---|
EnumTypeAnnotationTypeAdapter() |
| Modifier and Type | Method and Description |
|---|---|
EnumAnnotation |
read(com.google.gson.stream.JsonReader in) |
void |
write(com.google.gson.stream.JsonWriter out,
EnumAnnotation value) |
public void write(com.google.gson.stream.JsonWriter out,
EnumAnnotation value)
throws IOException
write in class com.google.gson.TypeAdapter<EnumAnnotation>IOExceptionpublic EnumAnnotation read(com.google.gson.stream.JsonReader in) throws IOException
read in class com.google.gson.TypeAdapter<EnumAnnotation>IOExceptionCopyright © 2022 MuleSoft, Inc.. All rights reserved.