lumis.portal.authentication
Interface IAuthenticationDao

Package class diagram package IAuthenticationDao
All Known Implementing Classes:
AuthenticationDaoJdbc

public interface IAuthenticationDao

This interface defines authentication related operations.

Since:
4.0.0

Method Summary
 void addUserSessionId(String userSessionId, String userId)
          Add the User Session Id.
 Collection<SessionConfig> clearInactiveSessions(int minutes, ITransaction transaction)
          Remove sessions inactive for the specified amount of minutes.
 void deleteUserSessionByUserId(String userId)
          Delete the User Session Id from the user id.
 void deleteUserSessionId(String userSessionId)
          Delete the User Session Id.
 Collection<SessionConfig> getSessionsByUserId(String userId, ITransaction transaction)
          Returns a collection of active session objects for the given user.
 String getUserId(String userSessionId, ITransaction transaction)
          Get the user id.
 void keepSessionAlive(String sessionId)
          Update the last access date for the given session.
 boolean validateUserLogin(String login, String password, ITransaction transaction)
          Validade the user login.
 String validateUserSession(String userSessionId, ITransaction transaction)
          Validate the session of the user.
 

Method Detail

addUserSessionId

void addUserSessionId(String userSessionId,
                      String userId)
                      throws DaoException,
                             PortalException
Add the User Session Id.

Parameters:
userSessionId -
userId -
Throws:
DaoException
PortalException

deleteUserSessionId

void deleteUserSessionId(String userSessionId)
                         throws DaoException,
                                PortalException
Delete the User Session Id.

Parameters:
userSessionId -
Throws:
DaoException
PortalException

deleteUserSessionByUserId

void deleteUserSessionByUserId(String userId)
                               throws DaoException,
                                      PortalException
Delete the User Session Id from the user id.

Parameters:
userId -
Throws:
DaoException
PortalException

validateUserSession

String validateUserSession(String userSessionId,
                           ITransaction transaction)
                           throws DaoException,
                                  PortalException
Validate the session of the user.

Parameters:
userSessionId - the user session id.
transaction - the transaction for persistence access.
Returns:
the userId if the user's session is valid, or null if it is not valid.
Throws:
DaoException
PortalException

getUserId

String getUserId(String userSessionId,
                 ITransaction transaction)
                 throws DaoException,
                        PortalException
Get the user id.

Parameters:
userSessionId -
transaction -
Returns:
a String.
Throws:
DaoException
PortalException

validateUserLogin

boolean validateUserLogin(String login,
                          String password,
                          ITransaction transaction)
                          throws DaoException,
                                 PortalException
Validade the user login.

Parameters:
login -
password -
transaction -
Returns:
true if the User's login is valid and false otherwise.
Throws:
DaoException
PortalException

keepSessionAlive

void keepSessionAlive(String sessionId)
                      throws PortalException
Update the last access date for the given session.

Parameters:
sessionId -
Throws:
DaoException
PortalException

clearInactiveSessions

Collection<SessionConfig> clearInactiveSessions(int minutes,
                                                ITransaction transaction)
                                                throws DaoException,
                                                       PortalException
Remove sessions inactive for the specified amount of minutes.

Parameters:
minutes - amount of minutes.
transaction - transaction for persistence access.
Returns:
the sessions cleared.
Throws:
DaoException
PortalException

getSessionsByUserId

Collection<SessionConfig> getSessionsByUserId(String userId,
                                              ITransaction transaction)
                                              throws PortalException
Returns a collection of active session objects for the given user.

Parameters:
userId -
transaction -
Returns:
Throws:
PortalException
Since:
4.0.11


Lumisportal  6.2.0.120405 - Copyright © 2006–2012 Lumis EIP Tecnologia da Informação LTDA. All Rights Reserved.