Package io.micronaut.inject.provider
Class JavaxProviderBeanDefinition
java.lang.Object
io.micronaut.inject.provider.AbstractProviderDefinition<javax.inject.Provider<Object>>
io.micronaut.inject.provider.JavaxProviderBeanDefinition
- All Implemented Interfaces:
AnnotationMetadata,AnnotationMetadataDelegate,AnnotationMetadataProvider,AnnotationSource,BeanInfo<javax.inject.Provider<Object>>,Named,Ordered,ArgumentCoercible<javax.inject.Provider<Object>>,BeanContextConditional,BeanDefinition<javax.inject.Provider<Object>>,BeanDefinitionReference<javax.inject.Provider<Object>>,BeanType<javax.inject.Provider<Object>>,InstantiatableBeanDefinition<javax.inject.Provider<Object>>,QualifiedBeanType<javax.inject.Provider<Object>>
@Internal
public final class JavaxProviderBeanDefinition
extends AbstractProviderDefinition<javax.inject.Provider<Object>>
Implementation for javax provider bean lookups.
- Since:
- 3.0.0
- Author:
- graemerocher
-
Field Summary
Fields inherited from interface io.micronaut.core.annotation.AnnotationMetadata
CLASS_NAME_SUFFIX, EMPTY_METADATA, VALUE_MEMBERFields inherited from interface io.micronaut.core.annotation.AnnotationSource
EMPTYFields inherited from interface io.micronaut.core.order.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected javax.inject.Provider<Object>buildProvider(BeanResolutionContext resolutionContext, BeanContext context, Argument<Object> argument, Qualifier<Object> qualifier, boolean singleton) Builds a provider implementation.Returns the bean type.booleanisEnabled(BeanContext context, BeanResolutionContext resolutionContext) Return whether this component is enabled for the given context.booleanMethods inherited from class io.micronaut.inject.provider.AbstractProviderDefinition
equals, getAnnotationMetadata, getBeanDefinitionName, getDeclaredQualifier, getTypeArguments, getTypeArguments, hashCode, instantiate, isAbstract, isAllowEmptyProviders, isCandidateBean, isConfigurationProperties, isContainerType, isSingleton, loadMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.micronaut.core.annotation.AnnotationMetadata
enumValuesSet, enumValuesSet, getValues, hasDeclaredStereotype, hasEvaluatedExpressions, hasStereotypeNonRepeating, isAnnotationPresent, isDeclaredAnnotationPresentMethods inherited from interface io.micronaut.core.annotation.AnnotationMetadataDelegate
booleanValue, booleanValue, booleanValue, booleanValue, classValue, classValue, classValue, classValue, classValues, classValues, classValues, classValues, copyAnnotationMetadata, doubleValue, doubleValue, doubleValue, enumValue, enumValue, enumValue, enumValue, enumValues, enumValues, enumValues, enumValues, findAnnotation, findAnnotation, findDeclaredAnnotation, findDeclaredAnnotation, findRepeatableAnnotation, findRepeatableAnnotation, getAnnotation, getAnnotation, getAnnotationNameByStereotype, getAnnotationNameByStereotype, getAnnotationNames, getAnnotationNamesByStereotype, getAnnotationNamesByStereotype, getAnnotationType, getAnnotationType, getAnnotationTypeByStereotype, getAnnotationTypeByStereotype, getAnnotationTypesByStereotype, getAnnotationTypesByStereotype, getAnnotationTypesByStereotype, getAnnotationValuesByName, getAnnotationValuesByStereotype, getAnnotationValuesByType, getDeclaredAnnotation, getDeclaredAnnotation, getDeclaredAnnotationNameByStereotype, getDeclaredAnnotationNames, getDeclaredAnnotationNamesByStereotype, getDeclaredAnnotationTypeByStereotype, getDeclaredAnnotationTypeByStereotype, getDeclaredAnnotationValuesByName, getDeclaredAnnotationValuesByType, getDeclaredMetadata, getDeclaredStereotypeAnnotationNames, getDefaultValue, getDefaultValue, getDefaultValue, getDefaultValue, getDefaultValues, getStereotypeAnnotationNames, getTargetAnnotationMetadata, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValues, getValues, hasAnnotation, hasAnnotation, hasDeclaredAnnotation, hasDeclaredAnnotation, hasDeclaredStereotype, hasDeclaredStereotype, hasDeclaredStereotype, hasPropertyExpressions, hasSimpleAnnotation, hasSimpleDeclaredAnnotation, hasStereotype, hasStereotype, hasStereotype, hasStereotype, intValue, intValue, intValue, isAnnotationPresent, isDeclaredAnnotationPresent, isEmpty, isFalse, isFalse, isPresent, isPresent, isRepeatableAnnotation, isRepeatableAnnotation, isTrue, isTrue, longValue, longValue, stringValue, stringValue, stringValue, stringValue, stringValues, stringValues, stringValues, stringValues, synthesize, synthesize, synthesizeAll, synthesizeAnnotationsByType, synthesizeDeclared, synthesizeDeclared, synthesizeDeclared, synthesizeDeclaredAnnotationsByTypeMethods inherited from interface io.micronaut.inject.BeanContextConditional
isEnabledMethods inherited from interface io.micronaut.inject.BeanDefinition
asArgument, findMethod, findPossibleMethods, getBeanDescription, getBeanDescription, getConstructor, getContainerElement, getDeclaringType, getExecutableMethods, getGenericBeanType, getInjectedFields, getInjectedMethods, getName, getPostConstructMethods, getPreDestroyMethods, getRequiredComponents, getRequiredMethod, getScope, getScopeName, getTypeArguments, getTypeInformation, getTypeParameters, getTypeParameters, hasAnnotatedMethod, isIterable, isProxy, resolveDynamicQualifierMethods inherited from interface io.micronaut.inject.BeanDefinitionReference
isContextScope, isProxiedBean, isProxyTarget, loadMethods inherited from interface io.micronaut.inject.BeanType
getBeanName, getExposedTypes, isPrimary, requiresMethodProcessingMethods inherited from interface io.micronaut.inject.InstantiatableBeanDefinition
instantiate
-
Constructor Details
-
JavaxProviderBeanDefinition
public JavaxProviderBeanDefinition()
-
-
Method Details
-
isEnabled
Description copied from interface:BeanContextConditionalReturn whether this component is enabled for the given context.- Specified by:
isEnabledin interfaceBeanContextConditional- Overrides:
isEnabledin classAbstractProviderDefinition<javax.inject.Provider<Object>>- Parameters:
context- The contextresolutionContext- The bean resolution context- Returns:
- True if it is
-
getBeanType
Description copied from interface:BeanTypeReturns the bean type.- Returns:
- The produced bean type
-
isPresent
public boolean isPresent()- Specified by:
isPresentin interfaceBeanDefinitionReference<javax.inject.Provider<Object>>- Overrides:
isPresentin classAbstractProviderDefinition<javax.inject.Provider<Object>>- Returns:
- Is the underlying bean type present on the classpath
-
buildProvider
protected javax.inject.Provider<Object> buildProvider(BeanResolutionContext resolutionContext, BeanContext context, Argument<Object> argument, Qualifier<Object> qualifier, boolean singleton) Description copied from class:AbstractProviderDefinitionBuilds a provider implementation.- Specified by:
buildProviderin classAbstractProviderDefinition<javax.inject.Provider<Object>>- Parameters:
resolutionContext- The resolution contextcontext- The contextargument- The argumentqualifier- The qualifiersingleton- Whether the bean is a singleton- Returns:
- The provider
-