public interface MessageStore
Modifier and Type | Method and Description |
---|---|
<T> Message<T> |
addMessage(Message<T> message)
Put the provided Message into the MessageStore.
|
Message<?> |
getMessage(java.util.UUID id)
Return the Message with the given id, or null if no Message with that id exists in the MessageStore.
|
long |
getMessageCount()
Optional attribute giving the number of messages in the store.
|
Message<?> |
removeMessage(java.util.UUID id)
Remove the Message with the given id from the MessageStore, if present, and return it.
|
Message<?> getMessage(java.util.UUID id)
<T> Message<T> addMessage(Message<T> message)
getMessage(UUID)
and removeMessage(UUID)
behave properly. Since messages are
immutable, putting the same message more than once is a no-op.Message<?> removeMessage(java.util.UUID id)
@ManagedAttribute long getMessageCount()
java.lang.UnsupportedOperationException
- if not implemented