Interface InterceptionModel
-
public interface InterceptionModel
Describes theInterceptorClassMetadata
s that apply to a particular entity. Implementors must implement equals() and hashcode() consistently- Author:
- Marius Bogoevici
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Set<InterceptorClassMetadata<?>>
getAllInterceptors()
Returns all interceptor classes that are applicable to the given intercepted entitySet<Annotation>
getClassInterceptorBindings()
List<InterceptorClassMetadata<?>>
getConstructorInvocationInterceptors()
ReturnsAroundConstruct
interceptors applicable for the given constructor.List<InterceptorClassMetadata<?>>
getInterceptors(InterceptionType interceptionType, Method method)
Returns the interceptors applicable for the given interception type and method.Set<Annotation>
getMemberInterceptorBindings(Member member)
TargetClassInterceptorMetadata
getTargetClassInterceptorMetadata()
Returns the interceptor metadata for the component class of this component.boolean
hasExternalConstructorInterceptors()
Indicates whether the given entity has associatedAroundConstruct
interceptors.boolean
hasExternalNonConstructorInterceptors()
Indicates whether the given entity has an associated interceptor of a kind other thanAroundConstruct
boolean
hasTargetClassInterceptors()
Indicates whether the given entity has target class interceptor methods.
-
-
-
Method Detail
-
getInterceptors
List<InterceptorClassMetadata<?>> getInterceptors(InterceptionType interceptionType, Method method)
Returns the interceptors applicable for the given interception type and method. For resolvingAroundConstruct
interceptors use#getConstructorInvocationInterceptors(java.lang.reflect.Constructor)
.- Parameters:
interceptionType
-method
- - null if the interception type is lifecycle- Returns:
- list of interceptors
- Throws:
IllegalArgumentException
- if interceptionType is business method or around timeout but method is null, as well as if interceptionType is callback and method is not null
-
getConstructorInvocationInterceptors
List<InterceptorClassMetadata<?>> getConstructorInvocationInterceptors()
ReturnsAroundConstruct
interceptors applicable for the given constructor.
-
getAllInterceptors
Set<InterceptorClassMetadata<?>> getAllInterceptors()
Returns all interceptor classes that are applicable to the given intercepted entity- Returns:
- all interceptors
-
hasExternalConstructorInterceptors
boolean hasExternalConstructorInterceptors()
Indicates whether the given entity has associatedAroundConstruct
interceptors.
-
hasExternalNonConstructorInterceptors
boolean hasExternalNonConstructorInterceptors()
Indicates whether the given entity has an associated interceptor of a kind other thanAroundConstruct
-
hasTargetClassInterceptors
boolean hasTargetClassInterceptors()
Indicates whether the given entity has target class interceptor methods.
-
getTargetClassInterceptorMetadata
TargetClassInterceptorMetadata getTargetClassInterceptorMetadata()
Returns the interceptor metadata for the component class of this component.- Returns:
- interceptor metadata for the component class
-
getClassInterceptorBindings
Set<Annotation> getClassInterceptorBindings()
- Returns:
- class-level interceptor bindings
-
getMemberInterceptorBindings
Set<Annotation> getMemberInterceptorBindings(Member member)
- Parameters:
method
-- Returns:
- method/constructor interceptor bindings
-
-