Package org.cyclos.impl.access
Class SessionTimeoutHandlerImpl
- java.lang.Object
-
- org.cyclos.impl.AbstractServerComponent
-
- org.cyclos.impl.AbstractGlobalServerComponent
-
- org.cyclos.impl.BaseGlobalHandlerImpl
-
- org.cyclos.impl.access.SessionTimeoutHandlerImpl
-
- All Implemented Interfaces:
SessionTimeoutHandler
@Component public class SessionTimeoutHandlerImpl extends BaseGlobalHandlerImpl implements SessionTimeoutHandler
Implementation forSessionTimeoutHandler
-
-
Field Summary
-
Fields inherited from class org.cyclos.impl.AbstractGlobalServerComponent
rawEntityManagerHandler
-
Fields inherited from class org.cyclos.impl.AbstractServerComponent
accountHandler, configurationHandler, dataTranslationHandler, notificationHandler, profileFieldHandler, transactionHandler, translationHandler
-
-
Constructor Summary
Constructors Constructor Description SessionTimeoutHandlerImpl()SessionTimeoutHandlerImpl(SharedStorage<String,Long> timeouts)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LonggetExpiration(String token)Returns the expiration for the given session token, if exists (returns null otherwise)Set<String>getExpired()Returns all expired session tokensvoidinitialize()voidremove(Collection<String> tokens)Removes all session information for the given tokensvoidset(String token, long timeout)Sets the session timeout for the given tokenvoidsetAll(Map<String,Long> map)Sets all expirations in the given map-
Methods inherited from class org.cyclos.impl.AbstractGlobalServerComponent
getBaseEntityManagerHandler, getEntityManager
-
Methods inherited from class org.cyclos.impl.AbstractServerComponent
dataTranslationProxy, dataTranslationProxy, delete, detach, doDataTranslationProxy, find, flush, from, getApplicationContext, getFormatter, getFormatter, getFormatter, getLogger, getRemoteAddress, getSessionData, mailContentBuilder, message, message, persist, processBatch, processBatch, refresh, remove, selectFrom, subQuery, update
-
-
-
-
Constructor Detail
-
SessionTimeoutHandlerImpl
public SessionTimeoutHandlerImpl()
-
SessionTimeoutHandlerImpl
public SessionTimeoutHandlerImpl(SharedStorage<String,Long> timeouts)
-
-
Method Detail
-
getExpiration
public Long getExpiration(String token)
Description copied from interface:SessionTimeoutHandlerReturns the expiration for the given session token, if exists (returns null otherwise)- Specified by:
getExpirationin interfaceSessionTimeoutHandler
-
getExpired
public Set<String> getExpired()
Description copied from interface:SessionTimeoutHandlerReturns all expired session tokens- Specified by:
getExpiredin interfaceSessionTimeoutHandler
-
initialize
@Autowired public void initialize()
-
remove
public void remove(Collection<String> tokens)
Description copied from interface:SessionTimeoutHandlerRemoves all session information for the given tokens- Specified by:
removein interfaceSessionTimeoutHandler
-
set
public void set(String token, long timeout)
Description copied from interface:SessionTimeoutHandlerSets the session timeout for the given token- Specified by:
setin interfaceSessionTimeoutHandler
-
setAll
public void setAll(Map<String,Long> map)
Description copied from interface:SessionTimeoutHandlerSets all expirations in the given map- Specified by:
setAllin interfaceSessionTimeoutHandler
-
-