Package com.qfs.snl.messages
Interface IMessageService.IMessageBox
- All Known Implementing Classes:
MessageBox
- Enclosing interface:
IMessageService
public static interface IMessageService.IMessageBox
IMessageBox interface represents ActiveMonitor Messages.
- Author:
- ActiveViam
-
Method Summary
Modifier and TypeMethodDescriptionvoidAnswers a message.voiddelete(long messageId) Deletes a message.Gets all messages received by a given recipient.voidmarkAsRead(long messageId) Marks the message as read.voidsubscribe(IMessageSubscriber client) Subscribes to all messages of a given recipient.voidunsubscribe(IMessageSubscriber client) Unsubscribes a client for a given recipient.
-
Method Details
-
getMessages
Collection<IMessage> getMessages()Gets all messages received by a given recipient.- Returns:
- the messages for in the mailbox
-
delete
Deletes a message.- Parameters:
messageId- id of the message to delete- Throws:
ServiceException- if an error occurs.
-
markAsRead
Marks the message as read.- Parameters:
messageId- id of the message to flag- Throws:
ServiceException- if an error occurs.
-
answer
Answers a message.- Parameters:
messageId- the id of the message to answeranswer- the content of the answer.- Throws:
ServiceException- if an error occurs.
-
subscribe
Subscribes to all messages of a given recipient.The messages are pushed to the subscriber as soon as they arrive.
- Parameters:
client- listener of messages.
-
unsubscribe
Unsubscribes a client for a given recipient.- Parameters:
client- listener to unsubscribe.
-