KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > struts > tiles > ControllerSupport


1 /*
2  * $Id: ControllerSupport.java 54929 2004-10-16 16:38:42Z germuska $
3  *
4  * Copyright 1999-2004 The Apache Software Foundation.
5  *
6  * Licensed under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  */

18
19 package org.apache.struts.tiles;
20
21 import java.io.IOException JavaDoc;
22
23 import javax.servlet.ServletContext JavaDoc;
24 import javax.servlet.ServletException JavaDoc;
25 import javax.servlet.http.HttpServletRequest JavaDoc;
26 import javax.servlet.http.HttpServletResponse JavaDoc;
27
28 /**
29  * Basic implementation of Controller. Implementations can extend this class
30  * to insulate themselves from changes in the <code>Controller</code>
31  * interface.
32  */

33 public class ControllerSupport implements Controller {
34
35     /**
36      * Method associated to a tile and called immediately before tile is
37      * included. This implementation does nothing.
38      * @param tileContext Current tile context.
39      * @param request Current request
40      * @param response Current response
41      * @param servletContext Current servlet context
42        * @deprecated Use execute() instead. This will be removed after
43        * Struts 1.2.
44      */

45     public void perform(
46         ComponentContext tileContext,
47         HttpServletRequest JavaDoc request,
48         HttpServletResponse JavaDoc response,
49         ServletContext JavaDoc servletContext)
50         throws ServletException JavaDoc, IOException JavaDoc {
51     }
52
53     /**
54      * @see org.apache.struts.tiles.Controller#execute(org.apache.struts.tiles.ComponentContext, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse, javax.servlet.ServletContext)
55      */

56     public void execute(
57         ComponentContext tileContext,
58         HttpServletRequest JavaDoc request,
59         HttpServletResponse JavaDoc response,
60         ServletContext JavaDoc servletContext)
61         throws Exception JavaDoc {
62
63             perform(tileContext, request, response, servletContext);
64     }
65 }
66
Popular Tags