KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > xpetstore > web > struts > action > signon > LogoutAction


1 package xpetstore.web.struts.action.signon;
2
3 import javax.servlet.http.HttpServletRequest JavaDoc;
4 import javax.servlet.http.HttpServletResponse JavaDoc;
5
6 import org.apache.struts.action.ActionForm;
7 import org.apache.struts.action.ActionForward;
8 import org.apache.struts.action.ActionMapping;
9
10 import xpetstore.web.struts.action.BaseAction;
11
12
13 /**
14  * @author <a HREF="mailto:tchbansi@sourceforge.net">Herve Tchepannou</a>
15  *
16  * @struts.action
17  * name="signonForm"
18  * path="/logout"
19  * scope="request"
20  * validate="false"
21  *
22  * @struts.action-forward
23  * name="success"
24  * path="/index.jsp"
25  */

26 public class LogoutAction
27     extends BaseAction
28 {
29     //~ Methods ----------------------------------------------------------------
30

31     /**
32      * @see xpetstore.web.struts.action.BaseAction#doExecute(ActionMapping, ActionForm, HttpServletRequest, HttpServletResponse)
33      */

34     protected ActionForward doExecute( ActionMapping mapping,
35                                        ActionForm form,
36                                        HttpServletRequest JavaDoc request,
37                                        HttpServletResponse JavaDoc response )
38         throws Exception JavaDoc
39     {
40         clearSession( request );
41         return mapping.findForward( SUCCESS );
42     }
43 }
44
Popular Tags