KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > opensubsystems > core > www > SessionValidator


1 /*
2  * Copyright (c) 2003 - 2007 OpenSubsystems s.r.o. Slovak Republic. All rights reserved.
3  *
4  * Project: OpenSubsystems
5  *
6  * $Id: SessionValidator.java,v 1.3 2007/01/07 06:14:09 bastafidli Exp $
7  *
8  * This program is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation; version 2 of the License.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, write to the Free Software
19  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20  */

21  
22 package org.opensubsystems.core.www;
23
24 import org.opensubsystems.core.error.OSSException;
25
26 /**
27  * This interface should be implemented by class which can validate session
28  * information. The implementing class is consulted for each request to make
29  * sure that the the user represented by the session is allowed to issue requests
30  * to the server.
31  *
32  * @version $Id: SessionValidator.java,v 1.3 2007/01/07 06:14:09 bastafidli Exp $
33  * @author Miro Halas
34  * @code.reviewer Miro Halas
35  * @code.reviewed Initial revision
36  */

37 public interface SessionValidator
38 {
39    /**
40     * Check if the session information is still valid. Valid session means that
41     * the session is authentic and was not yet invalidated.
42     *
43     * @param strSessionId - Session information to check
44     * @return boolean - if true the session is still valid and the user
45     * represented by this session is allowed to issue requests
46     * to the server
47     * @throws OSSException - error during checking
48     */

49    boolean checkSession(
50       String JavaDoc strSessionId
51    ) throws OSSException;
52 }
53
Popular Tags