1   /**
2    * Copyright 2005-2006 the original author or authors.
3    *
4    * Licensed under the Gnu General Pubic License, Version 2.0 (the
5    * "License"); you may not use this file except in compliance with
6    * the License. You may obtain a copy of the License at
7    *
8    *      http://www.opensource.org/licenses/gpl-license.php
9    *
10   * This program is distributed in the hope that it will be useful,
11   * but WITHOUT ANY WARRANTY; without even the implied warranty of
12   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13   * See the Gnu General Public License for more details.
14   */
15  package org.figure8.join.util;
16  
17  import org.apache.struts.action.ActionServlet;
18  
19  import javax.servlet.ServletContext;
20  /**
21   * This is a stub implementation of Struts ActionServlet. This implementation
22   * just allows us to set the ServletContext used by this servlet.
23   * @author <a href="mailto:laurent.broudoux@free.fr">Laurent Broudoux</a>
24   * @version $Revision: 1.2 $
25   */
26  public class ActionServletStub extends ActionServlet{
27  
28     // Attributes ---------------------------------------------------------------
29  
30     /** ServletContext used by this servlet */
31     private ServletContext context = null;
32  
33  
34     // Public -------------------------------------------------------------------
35  
36     /** @param context The ServletContext to use */
37     public void setServletContext(ServletContext context){
38        this.context = context;
39     }
40  
41  
42     // Override of GenericServlet -----------------------------------------------
43  
44     /** @return The ServletContext of this ActionServlet */
45     public ServletContext getServletContext(){
46        return context;
47     }
48  }