Package io.micronaut.aop
Interface InterceptorRegistry
- All Known Implementing Classes:
DefaultInterceptorRegistry
public interface InterceptorRegistry
Strategy interface for looking up interceptors from the bean context.
- Since:
- 3.0.0
- Author:
- graemerocher
-
Field Summary
Modifier and TypeFieldDescriptionstatic final Argument<InterceptorRegistry>
Constant for bean lookup. -
Method Summary
Modifier and TypeMethodDescription<T> @NonNull Interceptor<T,
T>[] resolveConstructorInterceptors
(@NonNull BeanConstructor<T> constructor, @NonNull Collection<BeanRegistration<Interceptor<T, T>>> interceptors) Resolves interceptors for the given constructor.<T> @NonNull Interceptor<T,
?>[] resolveInterceptors
(@NonNull Executable<T, ?> method, @NonNull Collection<BeanRegistration<Interceptor<T, ?>>> interceptors, @NonNull InterceptorKind interceptorKind) Resolves method interceptors for the given method.
-
Field Details
-
ARGUMENT
Constant for bean lookup.
-
-
Method Details
-
resolveInterceptors
@NonNull <T> @NonNull Interceptor<T,?>[] resolveInterceptors(@NonNull @NonNull Executable<T, ?> method, @NonNull @NonNull Collection<BeanRegistration<Interceptor<T, ?>>> interceptors, @NonNull @NonNull InterceptorKind interceptorKind) Resolves method interceptors for the given method.- Type Parameters:
T
- the bean type- Parameters:
method
- The method interceptorsinterceptors
- The pre-resolved interceptorsinterceptorKind
- The interceptor kind- Returns:
- An array of interceptors
-
resolveConstructorInterceptors
@NonNull <T> @NonNull Interceptor<T,T>[] resolveConstructorInterceptors(@NonNull @NonNull BeanConstructor<T> constructor, @NonNull @NonNull Collection<BeanRegistration<Interceptor<T, T>>> interceptors) Resolves interceptors for the given constructor.- Type Parameters:
T
- The bean type- Parameters:
constructor
- The constructorinterceptors
- The pre-resolved interceptors- Returns:
- An array of interceptors
-