Wolfizen

Custom MessageChannel Implementation [2/3]

Jan 11th, 2016
248
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.65 KB | None | 0 0
  1. public interface MutableMessageChannel<R,M> extends MessageChannel<R,M> {
  2.  
  3.     /**
  4.      * Adds a recipient to this MessageChannel
  5.      *
  6.      * @param recipient The recipient to add
  7.      *
  8.      * @return If the list of recipients changed as a result of this call
  9.      */
  10.     boolean addRecipient(R recipient);
  11.  
  12.     /**
  13.      * Clears the list of recipients
  14.      */
  15.     void clearRecipients();
  16.  
  17.     /**
  18.      * Removes a recipient to this MessageChannel
  19.      *
  20.      * @param recipient The recipient to remove
  21.      *
  22.      * @return If the list of recipients changed as a result of this call
  23.      */
  24.     boolean removeRecipient(R recipient);
  25. }
Advertisement
Add Comment
Please, Sign In to add comment