Package org.graylog.events.notifications
Class DBNotificationService
java.lang.Object
org.graylog2.database.PaginatedDbService<NotificationDto>
org.graylog.events.notifications.DBNotificationService
-
Field Summary
Fields inherited from class org.graylog2.database.PaginatedDbService
db
-
Constructor Summary
ConstructorDescriptionDBNotificationService
(MongoConnection mongoConnection, MongoJackObjectMapperProvider mapper, EntityOwnershipService entityOwnerShipService) -
Method Summary
Modifier and TypeMethodDescriptionint
Deletes thePaginatedDbService
for the given ID from the database.saveWithOwnership
(NotificationDto notificationDto, User user) searchPaginated
(SearchQuery query, Predicate<NotificationDto> filter, String sortByField, String sortOrder, int page, int perPage) Methods inherited from class org.graylog2.database.PaginatedDbService
asImmutableList, findPaginatedWithQueryAndSort, findPaginatedWithQueryFilterAndSort, findPaginatedWithQueryFilterAndSortWithGrandTotal, get, getMultiFieldSortBuilder, getPage, getSortBuilder, save, streamAll, streamByIds, streamQuery, streamQueryWithSort
-
Constructor Details
-
DBNotificationService
@Inject public DBNotificationService(MongoConnection mongoConnection, MongoJackObjectMapperProvider mapper, EntityOwnershipService entityOwnerShipService)
-
-
Method Details
-
searchPaginated
public PaginatedList<NotificationDto> searchPaginated(SearchQuery query, Predicate<NotificationDto> filter, String sortByField, String sortOrder, int page, int perPage) -
saveWithOwnership
-
delete
Description copied from class:PaginatedDbService
Deletes thePaginatedDbService
for the given ID from the database.- Overrides:
delete
in classPaginatedDbService<NotificationDto>
- Parameters:
id
- ID of thePaginatedDbService
to delete- Returns:
- the number of deleted documents
-