public final class JsonAdapterAnnotationTypeAdapterFactory extends java.lang.Object implements TypeAdapterFactory
JsonAdapter
and uses an instance of the
specified class as the default type adapter.Modifier and Type | Field and Description |
---|---|
private ConstructorConstructor |
constructorConstructor |
Constructor and Description |
---|
JsonAdapterAnnotationTypeAdapterFactory(ConstructorConstructor constructorConstructor) |
Modifier and Type | Method and Description |
---|---|
<T> TypeAdapter<T> |
create(Gson gson,
TypeToken<T> targetType)
Returns a type adapter for
type , or null if this factory doesn't
support type . |
(package private) TypeAdapter<?> |
getTypeAdapter(ConstructorConstructor constructorConstructor,
Gson gson,
TypeToken<?> type,
JsonAdapter annotation) |
private final ConstructorConstructor constructorConstructor
public JsonAdapterAnnotationTypeAdapterFactory(ConstructorConstructor constructorConstructor)
public <T> TypeAdapter<T> create(Gson gson, TypeToken<T> targetType)
TypeAdapterFactory
type
, or null if this factory doesn't
support type
.create
in interface TypeAdapterFactory
TypeAdapter<?> getTypeAdapter(ConstructorConstructor constructorConstructor, Gson gson, TypeToken<?> type, JsonAdapter annotation)