Interface NotificationStateAware
public interface NotificationStateAware
A domain that keeps track of
NotificationState
- Author:
- Jeff Fischer
-
Method Summary
Modifier and TypeMethodDescriptiondefault Optional<NotificationState>
findNotificationState
(String messageProducerType) Looks up a NotificationState from the states within this collectionRetrieve the message sending status for one or moreNotificationState
instances.default List<NotificationState>
getNotificationStates
(boolean fetch) Retrieve the message sending status for one or moreNotificationState
instances.void
setNotificationStates
(List<NotificationState> notificationStates) Set the message sending status for one or moreNotificationState
instances.
-
Method Details
-
getNotificationStates
List<NotificationState> getNotificationStates()Retrieve the message sending status for one or moreNotificationState
instances.- Returns:
- Retrieve the message sending status for one or more
NotificationState
instances.
-
getNotificationStates
Retrieve the message sending status for one or moreNotificationState
instances. Furthermore, specify whether the backing implementation should try to fetch associatedNotificationState
instances from the datastore, if applicable. By default, this simply delegates togetNotificationStates()
.- Parameters:
fetch
- Whether or not attempt to fetch from the back datastore, if required.- Returns:
- Retrieve the message sending status for one or more
NotificationState
instances.
-
setNotificationStates
Set the message sending status for one or moreNotificationState
instances. -
findNotificationState
Looks up a NotificationState from the states within this collection- Parameters:
messageProducerType
- an identifier for the message channel producing the message- Returns:
- an optional containing the NotificationState for the given message producer or an empty optional otherwise
-