Package com.logicaldoc.core.security.dao
Interface UserHistoryDAO
- 
- All Superinterfaces:
- PersistentObjectDAO<UserHistory>
 - All Known Implementing Classes:
- HibernateUserHistoryDAO
 
 public interface UserHistoryDAO extends PersistentObjectDAO<UserHistory> DAO forUserHistoryhandling.- Since:
- 5.0
- Author:
- Matteo Caruso - LogicalDOC
 
- 
- 
Method SummaryAll Methods Instance Methods Abstract Methods Modifier and Type Method Description voidcleanOldHistories(int ttl)This method deletes all the user history entries oldest than the given days from now.voidcreateUserHistory(User user, String eventType, String comment, String ip, String sessionId)Creates an user history entryList<UserHistory>findByUserId(long userId)This method selects all histories of a given user.- 
Methods inherited from interface com.logicaldoc.core.PersistentObjectDAObulkUpdate, delete, delete, deleteAll, deleteAll, findAll, findAll, findAllIds, findAllIds, findById, findById, findByObjectQuery, findByQuery, findByWhere, findByWhere, findIdsByWhere, findIdsByWhere, getDbms, initialize, isOracle, jdbcUpdate, jdbcUpdate, query, queryForInt, queryForList, queryForList, queryForLong, queryForObject, queryForRowSet, queryForString, store
 
- 
 
- 
- 
- 
Method Detail- 
findByUserIdList<UserHistory> findByUserId(long userId) This method selects all histories of a given user.- Parameters:
- userId- identifier of the suer
- Returns:
- list of histories ordered by date
 
 - 
createUserHistoryvoid createUserHistory(User user, String eventType, String comment, String ip, String sessionId) Creates an user history entry- Parameters:
- user- The user that made the operation
- eventType- The event type
- comment- The comment provided by the user
- ip- The remote IP
- sessionId- The user session id
 
 - 
cleanOldHistoriesvoid cleanOldHistories(int ttl) This method deletes all the user history entries oldest than the given days from now. Ifttlis 0 or -1, the cancellation is not made.- Parameters:
- ttl- The maximum number of days over which the history is considered old
 
 
- 
 
-