|
|
|
@ -1,5 +1,5 @@ |
|
|
|
/* |
|
|
|
/* |
|
|
|
* Copyright 2002-2020 the original author or authors. |
|
|
|
* Copyright 2002-2021 the original author or authors. |
|
|
|
* |
|
|
|
* |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License"); |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
* you may not use this file except in compliance with the License. |
|
|
|
@ -75,8 +75,9 @@ import org.springframework.web.method.HandlerMethod; |
|
|
|
public interface HandlerInterceptor { |
|
|
|
public interface HandlerInterceptor { |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* Intercept the execution of a handler. Called after HandlerMapping determined |
|
|
|
* Interception point before the execution of a handler. Called after |
|
|
|
* an appropriate handler object, but before HandlerAdapter invokes the handler. |
|
|
|
* HandlerMapping determined an appropriate handler object, but before |
|
|
|
|
|
|
|
* HandlerAdapter invokes the handler. |
|
|
|
* <p>DispatcherServlet processes a handler in an execution chain, consisting |
|
|
|
* <p>DispatcherServlet processes a handler in an execution chain, consisting |
|
|
|
* of any number of interceptors, with the handler itself at the end. |
|
|
|
* of any number of interceptors, with the handler itself at the end. |
|
|
|
* With this method, each interceptor can decide to abort the execution chain, |
|
|
|
* With this method, each interceptor can decide to abort the execution chain, |
|
|
|
@ -100,9 +101,10 @@ public interface HandlerInterceptor { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
/** |
|
|
|
* Intercept the execution of a handler. Called after HandlerAdapter actually |
|
|
|
* Interception point after successful execution of a handler. |
|
|
|
* invoked the handler, but before the DispatcherServlet renders the view. |
|
|
|
* Called after HandlerAdapter actually invoked the handler, but before the |
|
|
|
* Can expose additional model objects to the view via the given ModelAndView. |
|
|
|
* DispatcherServlet renders the view. Can expose additional model objects |
|
|
|
|
|
|
|
* to the view via the given ModelAndView. |
|
|
|
* <p>DispatcherServlet processes a handler in an execution chain, consisting |
|
|
|
* <p>DispatcherServlet processes a handler in an execution chain, consisting |
|
|
|
* of any number of interceptors, with the handler itself at the end. |
|
|
|
* of any number of interceptors, with the handler itself at the end. |
|
|
|
* With this method, each interceptor can post-process an execution, |
|
|
|
* With this method, each interceptor can post-process an execution, |
|
|
|
|