KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > efs > openreports > actions > LogoutAction


1 /*
2  * Copyright (C) 2004 Erik Swenson - eswenson@opensourcesoft.net
3  *
4  * This program is free software; you can redistribute it and/or modify it under
5  * the terms of the GNU General Public License as published by the Free Software
6  * Foundation; either version 2 of the License, or (at your option) any later
7  * version.
8  *
9  * This program is distributed in the hope that it will be useful, but WITHOUT
10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11  * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
12  * details.
13  *
14  * You should have received a copy of the GNU General Public License along with
15  * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
16  * Place - Suite 330, Boston, MA 02111-1307, USA.
17  *
18  */

19
20 package org.efs.openreports.actions;
21
22 import com.opensymphony.xwork.ActionContext;
23 import com.opensymphony.xwork.ActionSupport;
24
25 public class LogoutAction extends ActionSupport
26 {
27     public String JavaDoc execute()
28     {
29         ActionContext.getContext().getSession().clear();
30         ActionContext.getContext().getValueStack().setValue("loggedIn", new Boolean JavaDoc(false));
31         
32         return SUCCESS;
33     }
34
35 }
Popular Tags