|
|
|
@ -48,20 +48,10 @@ public class LoginHandlerInterceptor implements HandlerInterceptor {
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* Intercept the execution of a handler. Called after HandlerMapping determined |
|
|
|
|
* an appropriate handler object, but before HandlerAdapter invokes the handler. |
|
|
|
|
* <p>DispatcherServlet processes a handler in an execution chain, consisting |
|
|
|
|
* of any number of interceptors, with the handler itself at the end. |
|
|
|
|
* With this method, each interceptor can decide to abort the execution chain, |
|
|
|
|
* typically sending a HTTP error or writing a custom response. |
|
|
|
|
* <p><strong>Note:</strong> special considerations apply for asynchronous |
|
|
|
|
* request processing. For more details see |
|
|
|
|
* {@link org.springframework.web.servlet.AsyncHandlerInterceptor}. |
|
|
|
|
* @param request current HTTP request |
|
|
|
|
* @param response current HTTP response |
|
|
|
|
* @param handler chosen handler to execute, for type and/or instance evaluation |
|
|
|
|
* @return {@code 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. |
|
|
|
|
* @param request current HTTP request |
|
|
|
|
* @param response current HTTP response |
|
|
|
|
* @param handler chosen handler to execute, for type and/or instance evaluation |
|
|
|
|
* @return boolean true or false |
|
|
|
|
*/ |
|
|
|
|
@Override |
|
|
|
|
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) { |
|
|
|
|