HandlerMapping#getHandler method.
HandlerInterceptor
| Modifier and Type | Field and Description |
|---|---|
| private final Object | |
| private int | |
| private final List | |
| private static final Log |
| Access | Constructor and Description |
|---|---|
| public | HandlerExecutionChain(Object
the handler object to execute handler)Create a new HandlerExecutionChain. |
| public | HandlerExecutionChain(Object
the handler object to execute handler, HandlerInterceptor... the array of interceptors to apply
(in the given order) before the handler itself executes interceptors)Create a new HandlerExecutionChain. |
| public | HandlerExecutionChain(Object
the handler object to execute handler, List<HandlerInterceptor> the list of interceptors to apply
(in the given order) before the handler itself executes interceptorList)Create a new HandlerExecutionChain. |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public void | addInterceptor(int index, HandlerInterceptor interceptor)
Add the given interceptor at the specified index of this chain. |
| public void | addInterceptors(HandlerInterceptor... interceptors)
Add the given interceptors to the end of this chain. |
| pack-priv void | applyAfterConcurrentHandlingStarted(HttpServletRequest request, HttpServletResponse response)
Apply afterConcurrentHandlerStarted callback on mapped AsyncHandlerInterceptors. |
| pack-priv void | applyPostHandle(HttpServletRequest request, HttpServletResponse response, ModelAndView mv)
Apply postHandle methods of registered interceptors. |
| pack-priv boolean | Returns: true if the execution chain should proceed with the
next interceptor or the handler itself. Else, DispatcherServlet assumes
that this interceptor has already dealt with the response itself.Apply preHandle methods of registered interceptors. |
| public Object | |
| public List | Returns: the list of HandlerInterceptors instances (potentially empty)Return the list of interceptors to apply (in the given order). |
| public HandlerInterceptor[] | Returns: the array of HandlerInterceptors instances (may benull)Return the array of interceptors to apply (in the given order). |
| public String | toString()
Overrides java. Delegates to the handler's |
| pack-priv void | triggerAfterCompletion(HttpServletRequest request, HttpServletResponse response, Exception ex)
Trigger afterCompletion callbacks on the mapped HandlerInterceptors. |
| handler | back to summary |
|---|---|
| private final Object handler | |
| interceptorIndex | back to summary |
|---|---|
| private int interceptorIndex | |
| interceptorList | back to summary |
|---|---|
| private final List<HandlerInterceptor> interceptorList | |
| logger | back to summary |
|---|---|
| private static final Log logger | |
| HandlerExecutionChain | back to summary |
|---|---|
| public HandlerExecutionChain(Object handler) Create a new HandlerExecutionChain.
| |
| HandlerExecutionChain | back to summary |
|---|---|
| public HandlerExecutionChain(Object handler, HandlerInterceptor... interceptors) Create a new HandlerExecutionChain.
| |
| HandlerExecutionChain | back to summary |
|---|---|
| public HandlerExecutionChain(Object handler, List<HandlerInterceptor> interceptorList) Create a new HandlerExecutionChain.
| |
| addInterceptor | back to summary |
|---|---|
| public void addInterceptor(HandlerInterceptor interceptor) Add the given interceptor to the end of this chain. | |
| addInterceptor | back to summary |
|---|---|
| public void addInterceptor(int index, HandlerInterceptor interceptor) Add the given interceptor at the specified index of this chain.
| |
| addInterceptors | back to summary |
|---|---|
| public void addInterceptors(HandlerInterceptor... interceptors) Add the given interceptors to the end of this chain. | |
| applyAfterConcurrentHandlingStarted | back to summary |
|---|---|
| pack-priv void applyAfterConcurrentHandlingStarted(HttpServletRequest request, HttpServletResponse response) Apply afterConcurrentHandlerStarted callback on mapped AsyncHandlerInterceptors. | |
| applyPostHandle | back to summary |
|---|---|
| pack-priv void applyPostHandle(HttpServletRequest request, HttpServletResponse response, ModelAndView mv) throws Exception Apply postHandle methods of registered interceptors. | |
| applyPreHandle | back to summary |
|---|---|
| pack-priv boolean applyPreHandle(HttpServletRequest request, HttpServletResponse response) throws Exception Apply preHandle methods of registered interceptors.
| |
| getHandler | back to summary |
|---|---|
| public Object getHandler() Return the handler object to execute. | |
| getInterceptorList | back to summary |
|---|---|
| public List Return the list of interceptors to apply (in the given order).
| |
| getInterceptors | back to summary |
|---|---|
| public HandlerInterceptor[] getInterceptors() Return the array of interceptors to apply (in the given order).
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Delegates to the handler's
| |
| triggerAfterCompletion | back to summary |
|---|---|
| pack-priv void triggerAfterCompletion(HttpServletRequest request, HttpServletResponse response, Exception ex) Trigger afterCompletion callbacks on the mapped HandlerInterceptors. Will just invoke afterCompletion for all interceptors whose preHandle invocation has successfully completed and returned true. | |