Class AbstractValueTypeDeserializer<T>
- java.lang.Object
-
- org.eclipse.yasson.internal.serializer.AbstractValueTypeDeserializer<T>
-
- Type Parameters:
T- value type
- All Implemented Interfaces:
javax.json.bind.serializer.JsonbDeserializer<T>
- Direct Known Subclasses:
AbstractDateTimeDeserializer,AbstractNumberDeserializer,BooleanTypeDeserializer,ByteArrayBase64Deserializer,CharacterTypeDeserializer,DurationTypeDeserializer,EnumTypeDeserializer,JsonNumberTypeDeserializer,JsonStringTypeDeserializer,JsonValueDeserializer,NumberTypeDeserializer,OptionalDoubleTypeDeserializer,OptionalIntTypeDeserializer,OptionalLongTypeDeserializer,PathTypeDeserializer,PeriodTypeDeserializer,StringTypeDeserializer,TimeZoneTypeDeserializer,URITypeDeserializer,URLTypeDeserializer,UUIDTypeDeserializer,ZoneIdTypeDeserializer,ZoneOffsetTypeDeserializer
public abstract class AbstractValueTypeDeserializer<T> extends java.lang.Object implements javax.json.bind.serializer.JsonbDeserializer<T>Common type for all supported value type serializers.
-
-
Constructor Summary
Constructors Constructor Description AbstractValueTypeDeserializer(java.lang.Class<T> clazz, Customization customization)Creates a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Tdeserialize(java.lang.String jsonValue, Unmarshaller unmarshaller, java.lang.reflect.Type rtType)Convert string value to object.Tdeserialize(javax.json.stream.JsonParser parser, javax.json.bind.serializer.DeserializationContext ctx, java.lang.reflect.Type rtType)Extracts single string value for conversion.CustomizationgetCustomization()Returns customization of object.protected java.lang.Class<T>getPropertyType()Type of a property or creator parameter which is deserialized.
-
-
-
Constructor Detail
-
AbstractValueTypeDeserializer
public AbstractValueTypeDeserializer(java.lang.Class<T> clazz, Customization customization)
Creates a new instance.- Parameters:
clazz- Class to work with.customization- Model customization.
-
-
Method Detail
-
deserialize
public T deserialize(javax.json.stream.JsonParser parser, javax.json.bind.serializer.DeserializationContext ctx, java.lang.reflect.Type rtType)
Extracts single string value for conversion.- Specified by:
deserializein interfacejavax.json.bind.serializer.JsonbDeserializer<T>- Parameters:
parser- Parser to get value from.ctx- Unmarshaller.rtType- return type.- Returns:
- Deserialized object.
-
deserialize
protected T deserialize(java.lang.String jsonValue, Unmarshaller unmarshaller, java.lang.reflect.Type rtType)
Convert string value to object.- Parameters:
jsonValue- Json value.unmarshaller- Unmarshaller instance.rtType- Runtime type.- Returns:
- Deserialized object.
-
getCustomization
public Customization getCustomization()
Returns customization of object.- Returns:
- object customization
-
getPropertyType
protected java.lang.Class<T> getPropertyType()
Type of a property or creator parameter which is deserialized.- Returns:
- property type.
-
-