Class AbstractBeanMethod<B,T>
java.lang.Object
io.micronaut.core.beans.AbstractBeanMethod<B,T>
- Type Parameters:
B- The bean typeT- The return type
- All Implemented Interfaces:
AnnotationMetadataProvider, AnnotationSource, BeanMethod<B,T>, Named, Executable<B, T>
- Direct Known Subclasses:
AbstractExecutableBeanMethod
Abstract implementation of the
BeanMethod interface.- Since:
- 2.3.0
- Author:
- graemerocher
-
Field Summary
Fields inherited from interface AnnotationSource
EMPTY -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAbstractBeanMethod(BeanIntrospection<B> introspection, Argument<T> returnType, String name, @Nullable AnnotationMetadata annotationMetadata, Argument<?> @Nullable ... arguments) Default constructor. -
Method Summary
Modifier and TypeMethodDescriptionfinal AnnotationMetadataSupplies the metadata.final Argument<?>[]The required argument types.final StringgetName()final ReturnType<T> @Nullable TInvokes the method.protected abstract @Nullable TinvokeInternal(B instance, @Nullable Object... arguments) Abstract implementation implemented by generated byte code.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface AnnotationMetadataProvider
findAnnotation, findAnnotation, findDeclaredAnnotation, findDeclaredAnnotation, getTargetAnnotationMetadata, isAnnotationPresent, isDeclaredAnnotationPresent, synthesize, synthesizeAll, synthesizeAnnotationsByType, synthesizeDeclared, synthesizeDeclared, synthesizeDeclaredAnnotationsByTypeMethods inherited from interface AnnotationSource
getAnnotation, getAnnotation, getDeclaredAnnotation, getDeclaredAnnotation, isAnnotationPresent, isDeclaredAnnotationPresent, synthesize, synthesizeDeclaredMethods inherited from interface BeanMethod
getDeclaringType
-
Constructor Details
-
AbstractBeanMethod
protected AbstractBeanMethod(BeanIntrospection<B> introspection, Argument<T> returnType, String name, @Nullable AnnotationMetadata annotationMetadata, Argument<?> @Nullable ... arguments) Default constructor.- Parameters:
introspection- The associated introspectionreturnType- The return typename- The name of the methodannotationMetadata- The annotation metadataarguments- The argument types
-
-
Method Details
-
getDeclaringBean
- Specified by:
getDeclaringBeanin interfaceBeanMethod<B,T> - Returns:
- The declaring bean introspection.
-
getReturnType
- Specified by:
getReturnTypein interfaceBeanMethod<B,T> - Returns:
- The return type.
-
getAnnotationMetadata
Description copied from interface:AnnotationMetadataProviderSupplies the metadata. Defaults toAnnotationMetadata.EMPTY_METADATA.- Specified by:
getAnnotationMetadatain interfaceAnnotationMetadataProvider- Returns:
- The
AnnotationMetadata
-
getName
-
getArguments
Description copied from interface:ExecutableThe required argument types.- Specified by:
getArgumentsin interfaceExecutable<B,T> - Returns:
- The arguments
-
invoke
Description copied from interface:ExecutableInvokes the method.- Specified by:
invokein interfaceExecutable<B,T> - Parameters:
instance- The instance. Nullable only if it's a static method call.arguments- The arguments- Returns:
- The result
-
invokeInternal
-