Package io.micronaut.core.convert
Interface ArgumentConversionContext<T>
- Type Parameters:
T
- The type
- All Superinterfaces:
AnnotationMetadataProvider
,AnnotationSource
,ConversionContext
,ErrorsContext
,Iterable<ConversionError>
,TypeVariableResolver
- All Known Subinterfaces:
ImmutableArgumentConversionContext<T>
Extended version of the
ConversionContext
specifically for conversion Argument
instances.- Since:
- 1.0
- Author:
- Graeme Rocher
-
Field Summary
Fields inherited from interface io.micronaut.core.annotation.AnnotationSource
EMPTY
Fields inherited from interface io.micronaut.core.convert.ConversionContext
BOOLEAN, DEFAULT, INT, LIST_OF_STRING, LONG, MAP, STRING
-
Method Summary
Modifier and TypeMethodDescriptiondefault AnnotationMetadata
Supplies the metadata.default Argument[]
In the case where the type to be converted contains generic type arguments this map will return the concrete types of those arguments.default ArgumentConversionContext<T>
with
(AnnotationMetadata annotationMetadata) Augment this context with annotation metadata.Methods inherited from interface io.micronaut.core.annotation.AnnotationMetadataProvider
findAnnotation, findAnnotation, findDeclaredAnnotation, findDeclaredAnnotation, getTargetAnnotationMetadata, isAnnotationPresent, isDeclaredAnnotationPresent, synthesize, synthesizeAll, synthesizeAnnotationsByType, synthesizeDeclared, synthesizeDeclared, synthesizeDeclaredAnnotationsByType
Methods inherited from interface io.micronaut.core.annotation.AnnotationSource
getAnnotation, getAnnotation, getDeclaredAnnotation, getDeclaredAnnotation, isAnnotationPresent, isDeclaredAnnotationPresent, synthesize, synthesizeDeclared
Methods inherited from interface io.micronaut.core.convert.ConversionContext
getCharset, getLocale, with
Methods inherited from interface io.micronaut.core.convert.ErrorsContext
getLastError, hasErrors, iterator, reject, reject
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface io.micronaut.core.type.TypeVariableResolver
getFirstTypeVariable, getTypeVariable
-
Method Details
-
getArgument
- Returns:
- The
Argument
being converted
-
getTypeParameters
- Specified by:
getTypeParameters
in interfaceTypeVariableResolver
- Returns:
- The type parameters as an array
-
getTypeVariables
Description copied from interface:ConversionContext
In the case where the type to be converted contains generic type arguments this map will return the concrete types of those arguments. For example for theMap
type two keys will be present called 'K' and 'V' with the actual types of the key and value.- Specified by:
getTypeVariables
in interfaceConversionContext
- Specified by:
getTypeVariables
in interfaceTypeVariableResolver
- Returns:
- A map of type variables
-
getAnnotationMetadata
Description copied from interface:AnnotationMetadataProvider
Supplies the metadata. Defaults toAnnotationMetadata.EMPTY_METADATA
.- Specified by:
getAnnotationMetadata
in interfaceAnnotationMetadataProvider
- Returns:
- The
AnnotationMetadata
-
with
Augment this context with annotation metadata.- Parameters:
annotationMetadata
- The annotation metadata- Returns:
- The conversion context
-