Class UuidIdentifierConverter
java.lang.Object
de.vinado.spring.identifier.convert.UuidIdentifierConverter
- All Implemented Interfaces:
ConditionalConverter,ConditionalGenericConverter,GenericConverter
@ReadingConverter
public class UuidIdentifierConverter
extends Object
implements ConditionalGenericConverter
- Author:
- Vincent Nadoll
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.springframework.core.convert.converter.GenericConverter
GenericConverter.ConvertiblePair -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final TypeDescriptorprotected static final TypeDescriptorprotected static final TypeDescriptor -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionconvert(Object source, TypeDescriptor sourceType, TypeDescriptor targetType) protected UuidIdentifierconvertNonNull(Object source, TypeDescriptor sourceType, TypeDescriptor targetType) booleanmatches(TypeDescriptor sourceType, TypeDescriptor targetType)
-
Field Details
-
STRING_TYPE
-
UUID_TYPE
-
IDENTIFIER_TYPE
-
-
Constructor Details
-
UuidIdentifierConverter
public UuidIdentifierConverter()
-
-
Method Details
-
matches
- Specified by:
matchesin interfaceConditionalConverter
-
getConvertibleTypes
- Specified by:
getConvertibleTypesin interfaceGenericConverter
-
convert
@Nullable public Object convert(@Nullable Object source, TypeDescriptor sourceType, TypeDescriptor targetType) - Specified by:
convertin interfaceGenericConverter
-
convertNonNull
protected UuidIdentifier convertNonNull(Object source, TypeDescriptor sourceType, TypeDescriptor targetType) throws ConversionFailedException - Throws:
ConversionFailedException
-