class JavaTimeArgumentConverter extends SimpleArgumentConverter implements AnnotationConsumer<JavaTimeConversionPattern>
| Modifier and Type | Field and Description |
|---|---|
private java.lang.String |
pattern |
private static java.util.Map<java.lang.Class<?>,java.time.temporal.TemporalQuery<?>> |
TEMPORAL_QUERIES |
| Constructor and Description |
|---|
JavaTimeArgumentConverter() |
| Modifier and Type | Method and Description |
|---|---|
void |
accept(JavaTimeConversionPattern annotation) |
java.lang.Object |
convert(java.lang.Object input,
java.lang.Class<?> targetClass)
Convert the supplied
source object into to the supplied
targetType. |
convertprivate static final java.util.Map<java.lang.Class<?>,java.time.temporal.TemporalQuery<?>> TEMPORAL_QUERIES
private java.lang.String pattern
public void accept(JavaTimeConversionPattern annotation)
accept in interface java.util.function.Consumer<JavaTimeConversionPattern>public java.lang.Object convert(java.lang.Object input,
java.lang.Class<?> targetClass)
throws ArgumentConversionException
SimpleArgumentConvertersource object into to the supplied
targetType.convert in class SimpleArgumentConverterinput - the source object to convert; may be nulltargetClass - the target type the source object should be converted
into; never nullnull but only if the target
type is a reference typeArgumentConversionException - in case an error occurs during the
conversion