Interface HelidonInterceptor<W>
- 
- Type Parameters:
 W- type of the work item processed by the interceptor
- All Known Subinterfaces:
 HelidonInterceptor.WithPostCompletion<W>
- All Known Implementing Classes:
 HelidonInterceptor.Base
public interface HelidonInterceptor<W>Common behavior for interceptors, invoking a preInvocation method before running an interceptedExecutable.Implementing classes typically extend
HelidonInterceptor.Base.See also the
HelidonInterceptor.WithPostCompletioninterface. 
- 
- 
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classHelidonInterceptor.Base<W>HelidonInterceptorimplementation providing as much logic as possible.static interfaceHelidonInterceptor.WithPostCompletion<W>Common behavior among interceptors with both pre-invocation and post-completion behavior. 
- 
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description ObjectaroundConstruct(javax.interceptor.InvocationContext context)Invoked during the intercepted constructor invocation.default ObjectaroundConstruction(javax.interceptor.InvocationContext context)Invokes the implementation'spreInvocationlogic for a constructor, once for each work item associated with the constructor.default ObjectaroundInvocation(javax.interceptor.InvocationContext context)Invokes the implementation's preInvocation logic for a method, once for each work item associated with the method.ObjectaroundInvoke(javax.interceptor.InvocationContext context)Invoked during the intercepted method invocation.voidpreInvocation(javax.interceptor.InvocationContext context, W workItem)Performs whatever pre-invocation work is needed for the given context, applied to the specified work item.Iterable<W>workItems(Executable executable)Returns the work items the specific interceptor instance should process. 
 - 
 
- 
- 
Method Detail
- 
aroundConstruction
default Object aroundConstruction(javax.interceptor.InvocationContext context) throws Exception
Invokes the implementation'spreInvocationlogic for a constructor, once for each work item associated with the constructor.- Parameters:
 context-InvocationContext- Returns:
 - any value returned by the intercepted 
Executable - Throws:
 Exception- when the intercepted code throws an exception
 
- 
aroundConstruct
Object aroundConstruct(javax.interceptor.InvocationContext context) throws Exception
Invoked during the intercepted constructor invocation.Typically, concrete implementations should extend
HelidonInterceptor.Basewhich implements this method with@AroundConstruct. Annotation processing for@AroundConstructdoes not recognize the annotation on adefaultmethod implementation defined on the interface.- Parameters:
 context- the invocation context for the intercepted call- Returns:
 - the value returned from the intercepted constructor
 - Throws:
 Exception- if the invoked constructor throws an exception
 
- 
aroundInvocation
default Object aroundInvocation(javax.interceptor.InvocationContext context) throws Exception
Invokes the implementation's preInvocation logic for a method, once for each work item associated with the method.- Parameters:
 context-InvocationContext- Returns:
 - any value returned by the intercepted 
Executable - Throws:
 Exception- when the intercepted code throws an exception
 
- 
aroundInvoke
Object aroundInvoke(javax.interceptor.InvocationContext context) throws Exception
Invoked during the intercepted method invocation.Typically, concrete implementations should extend
HelidonInterceptor.Basewhich implements this method with@AroundInvoke. Annotation processing for@AroundInvokedoes not recognize the annotation on adefaultmethod implementation defined on the interface.- Parameters:
 context- the invocation context for the intercepted call- Returns:
 - the value returned from the intercepted method
 - Throws:
 Exception- if the invoked method throws an exception
 
- 
workItems
Iterable<W> workItems(Executable executable)
Returns the work items the specific interceptor instance should process.- Parameters:
 executable- the specificExecutablebeing intercepted- Returns:
 - the work items pertinent to the specified 
Executable 
 
- 
preInvocation
void preInvocation(javax.interceptor.InvocationContext context, W workItem)Performs whatever pre-invocation work is needed for the given context, applied to the specified work item.If the pre-invocation handler throws an exception, any other pre-invocation
- Parameters:
 context-InvocationContextfor the execution being interceptedworkItem- the work item on which to operate
 
 - 
 
 -