Package com.logicaldoc.core.security
Interface SessionDAO
- All Superinterfaces:
- PersistentObjectDAO<Session>
- All Known Implementing Classes:
- HibernateSessionDAO
DAO for 
UserSession handling.- Since:
- 7.7
- Author:
- Marco Meschieri - LogicalDOC
- 
Field SummaryFields inherited from interface com.logicaldoc.core.PersistentObjectDAOENTITY
- 
Method SummaryModifier and TypeMethodDescriptionvoidcleanOldSessions(int ttl) This method deletes all the session entries oldest than the given days since now.intcountSessions(Long tenantId, Integer status) Counts the number of sessions.voidRemoves all the sessions that refers to the current nodefindByNode(String node) Retrieves the session of the given nodeRetrieves the session of the given SIDMethods inherited from interface com.logicaldoc.core.PersistentObjectDAObulkUpdate, delete, delete, deleteAll, deleteAll, evict, evict, findAll, findAll, findAllIds, findAllIds, findById, findById, findByObjectQuery, findByQuery, findByQuery, findByWhere, findByWhere, findIdsByWhere, findIdsByWhere, getDatabaseMetadata, getDbms, initialize, isMySQL, isOracle, jdbcUpdate, jdbcUpdate, query, query, queryForDouble, queryForDouble, queryForInt, queryForInt, queryForList, queryForList, queryForList, queryForLong, queryForLong, queryForObject, queryForObject, queryForResultSet, queryForString, queryForString, store
- 
Method Details- 
deleteCurrentNodeSessionsvoid deleteCurrentNodeSessions()Removes all the sessions that refers to the current node
- 
countSessionsCounts the number of sessions.- Parameters:
- tenantId- The tenant (optional)
- status- The current status (optional)
- Returns:
- the number of sessions
 
- 
findBySidRetrieves the session of the given SID- Parameters:
- sid- identifier of the session
- Returns:
- the session
 
- 
findByNodeRetrieves the session of the given node- Parameters:
- node- the node
- Returns:
- the list of sessions
 
- 
cleanOldSessionsvoid cleanOldSessions(int ttl) This method deletes all the session entries oldest than the given days since now. Ifttlis 0 or -1, the deletion is not made.- Parameters:
- ttl- The maximum number of days over which the session is considered old
 
 
-