Class JdbcUserEventDao
java.lang.Object
net.solarnetwork.central.common.dao.jdbc.JdbcUserEventDao
- All Implemented Interfaces:
UserEventAppenderDao,UserEventDao,UserEventMaintenanceDao,net.solarnetwork.dao.FilterableDao<UserEvent,UserUuidPK, UserEventFilter>
JDBC implementation of
UserEventDao.-
Nested Class Summary
Nested classes/interfaces inherited from interface net.solarnetwork.central.common.dao.UserEventMaintenanceDao
UserEventMaintenanceDao.UserEventPurgeFilter -
Constructor Summary
ConstructorsConstructorDescriptionJdbcUserEventDao(org.springframework.jdbc.core.JdbcOperations jdbcOps) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoidAdd an event.net.solarnetwork.dao.FilterResults<UserEvent, UserUuidPK> findFiltered(UserEventFilter filter, List<net.solarnetwork.domain.SortDescriptor> sorts, Integer offset, Integer max) voidfindFilteredStream(UserEventFilter filter, FilteredResultsProcessor<UserEvent> processor) API for querying for a filtered stream ofUserEvententities.longPurge events matching the given filter.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.solarnetwork.dao.FilterableDao
findFiltered
-
Constructor Details
-
JdbcUserEventDao
public JdbcUserEventDao(org.springframework.jdbc.core.JdbcOperations jdbcOps) Constructor.- Parameters:
jdbcOps- the JDBC operations- Throws:
IllegalArgumentException- if any argument is null
-
-
Method Details
-
add
Description copied from interface:UserEventAppenderDaoAdd an event.- Specified by:
addin interfaceUserEventAppenderDao- Parameters:
event- the event to add
-
findFiltered
public net.solarnetwork.dao.FilterResults<UserEvent,UserUuidPK> findFiltered(UserEventFilter filter, List<net.solarnetwork.domain.SortDescriptor> sorts, Integer offset, Integer max) - Specified by:
findFilteredin interfacenet.solarnetwork.dao.FilterableDao<UserEvent,UserUuidPK, UserEventFilter>
-
purgeEvents
Description copied from interface:UserEventMaintenanceDaoPurge events matching the given filter.- Specified by:
purgeEventsin interfaceUserEventMaintenanceDao- Parameters:
filter- the criteria of the events to purge- Returns:
- the number of tasks deleted
-
findFilteredStream
public void findFilteredStream(UserEventFilter filter, FilteredResultsProcessor<UserEvent> processor) throws IOException Description copied from interface:UserEventDaoAPI for querying for a filtered stream ofUserEvententities.- Specified by:
findFilteredStreamin interfaceUserEventDao- Parameters:
filter- the filterprocessor- the stream processor- Throws:
IOException- if any IO error occurs
-