View Javadoc
1   /**************************************************************************
2    Copyright 2005 Webstersmalley
3   
4    Licensed under the Apache License, Version 2.0 (the "License");
5    you may not use this file except in compliance with the License.
6    You may obtain a copy of the License at
7   
8    http://www.apache.org/licenses/LICENSE-2.0
9   
10   Unless required by applicable law or agreed to in writing, software
11   distributed under the License is distributed on an "AS IS" BASIS,
12   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   See the License for the specific language governing permissions and
14   limitations under the License.
15   *************************************************************************/
16  /*
17   * Created on 09-Aug-2005
18   */
19  package com.webstersmalley.chessweb.web;
20  
21  import java.io.IOException;
22  
23  import javax.servlet.ServletException;
24  import javax.servlet.http.HttpServletRequest;
25  import javax.servlet.http.HttpServletResponse;
26  
27  import org.apache.commons.logging.Log;
28  import org.apache.commons.logging.LogFactory;
29  import org.springframework.web.servlet.ModelAndView;
30  import org.springframework.web.servlet.mvc.Controller;
31  
32  /***
33   * Controller for the refresh all frame.
34   * 
35   * @author Matthew Smalley
36   */
37  public class RefreshAllController implements Controller {
38      /*** Logger for this class and subclasses. */
39      private final Log logger = LogFactory.getLog(getClass());
40  
41      /***
42       * Handles the request & returns a model/view.
43       * @param request the servlet request.
44       * @param response the servlet response.
45       * @throws ServletException if there's a problem with the servlet.
46       * @throws IOException for any other IO related issues.
47       * @return the ModelAndView
48       * @implements org.springframework.web.servlet.mvc.Controller.handleRequest
49       */
50      public final ModelAndView handleRequest(final HttpServletRequest request,
51              final HttpServletResponse response) throws ServletException,
52              IOException {
53          logger.info("Forwarding to jsp now");
54          return new ModelAndView("RefreshAll");
55      }
56  }