
Package ca.uhn.fhir.interceptor.api
Interface IBaseInterceptorBroadcaster<POINTCUT extends IPointcut>
- All Known Subinterfaces:
IBaseInterceptorService<POINTCUT>,IInterceptorBroadcaster,IInterceptorService
- All Known Implementing Classes:
BaseInterceptorService,InterceptorService
public interface IBaseInterceptorBroadcaster<POINTCUT extends IPointcut>
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceA filter hook is a hook that wraps a system call, and allows a hook to run code before and after the supplied function.static interface -
Method Summary
Modifier and TypeMethodDescriptionbooleancallHooks(POINTCUT thePointcut, HookParams theParams) Invoke registered interceptor hook methods for the given Pointcut.callHooksAndReturnObject(POINTCUT thePointcut, HookParams theParams) Invoke registered interceptor hook methods for the given Pointcut.getInvokersForPointcut(POINTCUT thePointcut) booleanDoes this broadcaster have any hooks for the given pointcut?default booleanifHasCallHooks(POINTCUT thePointcut, Supplier<HookParams> theParamsSupplier) A supplier-based callHooks() for lazy construction of the HookParameters.default ObjectifHasCallHooksAndReturnObject(POINTCUT thePointcut, Supplier<HookParams> theParams) A supplier-based version of callHooksAndReturnObject for lazy construction of the params.default voidrunWithFilterHooks(POINTCUT thePointcut, HookParams theHookParams, Runnable theRunnable) default <T> TrunWithFilterHooks(POINTCUT thePointcut, HookParams theHookParams, Supplier<T> theSupplier)
-
Method Details
-
callHooks
Invoke registered interceptor hook methods for the given Pointcut.- Returns:
- Returns
falseif any of the invoked hook methods returnedfalse, and returnstrueotherwise.
-
ifHasCallHooks
A supplier-based callHooks() for lazy construction of the HookParameters.- Returns:
- false if any hook methods return false, return true otherwise.
-
callHooksAndReturnObject
Invoke registered interceptor hook methods for the given Pointcut. This method should only be called for pointcuts that return a type other thanvoidorboolean- Returns:
- Returns the object returned by the first hook method that did not return
null
-
ifHasCallHooksAndReturnObject
A supplier-based version of callHooksAndReturnObject for lazy construction of the params.- Returns:
- Returns the object returned by the first hook method that did not return
nullornull
-
runWithFilterHooks
default void runWithFilterHooks(POINTCUT thePointcut, HookParams theHookParams, Runnable theRunnable) -
runWithFilterHooks
default <T> T runWithFilterHooks(POINTCUT thePointcut, HookParams theHookParams, Supplier<T> theSupplier) -
hasHooks
Does this broadcaster have any hooks for the given pointcut?- Parameters:
thePointcut- The poointcut- Returns:
- Does this broadcaster have any hooks for the given pointcut?
- Since:
- 4.0.0
-
getInvokersForPointcut
-