ObjectToOptionalConverter needs to be marked as @UsesJava8

This commit is contained in:
Juergen Hoeller
2014-06-18 23:39:19 +02:00
parent 88eabe874c
commit ef25b9e7af

View File

@@ -16,14 +16,15 @@
package org.springframework.core.convert.support;
import org.springframework.core.convert.ConversionService;
import org.springframework.core.convert.TypeDescriptor;
import org.springframework.core.convert.converter.ConditionalGenericConverter;
import java.util.Collections;
import java.util.Optional;
import java.util.Set;
import org.springframework.core.convert.ConversionService;
import org.springframework.core.convert.TypeDescriptor;
import org.springframework.core.convert.converter.ConditionalGenericConverter;
import org.springframework.lang.UsesJava8;
/**
* Convert an Object to {@code java.util.Optional<T>} if necessary using the
* {@code ConversionService} to convert the source Object to the generic type
@@ -32,6 +33,7 @@ import java.util.Set;
* @author Rossen Stoyanchev
* @since 4.1
*/
@UsesJava8
final class ObjectToOptionalConverter implements ConditionalGenericConverter {
private final ConversionService conversionService;
@@ -78,4 +80,5 @@ final class ObjectToOptionalConverter implements ConditionalGenericConverter {
super(typeDescriptor.getResolvableType().getGeneric(0), null, typeDescriptor.getAnnotations());
}
}
}