Interface AnnouncementChannel<T extends AnnouncementMessage>

  • All Superinterfaces:
    org.sakaiproject.entity.api.Entity, org.sakaiproject.message.api.MessageChannel<T>
    All Known Subinterfaces:
    AnnouncementChannelEdit

    public interface AnnouncementChannel<T extends AnnouncementMessage>
    extends org.sakaiproject.message.api.MessageChannel<T>

    AnnouncementChannel is the extension to the MessageChanel interface for a Sakai Announcement service announcement channel.

    • Nested Class Summary

      • Nested classes/interfaces inherited from interface org.sakaiproject.entity.api.Entity

        org.sakaiproject.entity.api.Entity.UrlType
    • Field Summary

      • Fields inherited from interface org.sakaiproject.entity.api.Entity

        SEPARATOR
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      AnnouncementMessageEdit addAnnouncementMessage()
      a (AnnouncementMessage) cover for addMessage to add a new message to this channel.
      AnnouncementMessage addAnnouncementMessage​(String subject, boolean draft, List attachments, String body)
      a (AnnouncementMessage) cover for addMessage to add a new message to this channel.
      AnnouncementMessageEdit editAnnouncementMessage​(String messageId)
      A (AnnouncementMessageEdit) cover for editMessage.
      AnnouncementMessage getAnnouncementMessage​(String messageId)
      A (AnnouncementMessage) cover for getMessage to return a specific announcement channel message, as specified by message id.
      void removeAnnouncementMessage​(String messageId)
      A cover for removeMessage.
      • Methods inherited from interface org.sakaiproject.entity.api.Entity

        getId, getProperties, getReference, getReference, getUrl, getUrl, toXml
      • Methods inherited from interface org.sakaiproject.message.api.MessageChannel

        addMessage, allowAddChannelMessage, allowAddDraftMessage, allowAddMessage, allowEditMessage, allowGetMessages, allowRemoveMessage, cancelMessage, commitMessage, commitMessage, commitMessage, commitMessage_order, editMessage, getContext, getCount, getCount, getGroupsAllowAddMessage, getGroupsAllowGetMessage, getGroupsAllowRemoveMessage, getMessage, getMessages, getMessages, getMessagesPublic, mergeMessage, removeMessage, removeMessage
    • Method Detail

      • getAnnouncementMessage

        AnnouncementMessage getAnnouncementMessage​(String messageId)
                                            throws org.sakaiproject.exception.IdUnusedException,
                                                   org.sakaiproject.exception.PermissionException
        A (AnnouncementMessage) cover for getMessage to return a specific announcement channel message, as specified by message id.
        Parameters:
        messageId - The id of the message to get.
        Returns:
        the AnnouncementMessage that has the specified id.
        Throws:
        org.sakaiproject.exception.IdUnusedException - If this name is not a defined message in this announcement channel.
        org.sakaiproject.exception.PermissionException - If the user does not have any permissions to read the message.
      • editAnnouncementMessage

        AnnouncementMessageEdit editAnnouncementMessage​(String messageId)
                                                 throws org.sakaiproject.exception.IdUnusedException,
                                                        org.sakaiproject.exception.PermissionException,
                                                        org.sakaiproject.exception.InUseException
        A (AnnouncementMessageEdit) cover for editMessage. Return a specific channel message, as specified by message name, locked for update. Must commitEdit() to make official, or cancelEdit() when done!
        Parameters:
        messageId - The id of the message to get.
        Returns:
        the Message that has the specified id.
        Throws:
        org.sakaiproject.exception.IdUnusedException - If this name is not a defined message in this channel.
        org.sakaiproject.exception.PermissionException - If the user does not have any permissions to read the message.
        org.sakaiproject.exception.InUseException - if the current user does not have permission to mess with this user.
      • removeAnnouncementMessage

        void removeAnnouncementMessage​(String messageId)
                                throws org.sakaiproject.exception.PermissionException
        A cover for removeMessage. Deletes the messages specified by the message id.
        Parameters:
        messageId - The id of the message to get.
        Throws:
        org.sakaiproject.exception.PermissionException - If the user does not have any permissions to delete the message.
      • addAnnouncementMessage

        AnnouncementMessageEdit addAnnouncementMessage()
                                                throws org.sakaiproject.exception.PermissionException
        a (AnnouncementMessage) cover for addMessage to add a new message to this channel. Must commitEdit() to make official, or cancelEdit() when done!
        Returns:
        The newly added message, locked for update.
        Throws:
        org.sakaiproject.exception.PermissionException - If the user does not have write permission to the channel.
      • addAnnouncementMessage

        AnnouncementMessage addAnnouncementMessage​(String subject,
                                                   boolean draft,
                                                   List attachments,
                                                   String body)
                                            throws org.sakaiproject.exception.PermissionException
        a (AnnouncementMessage) cover for addMessage to add a new message to this channel.
        Parameters:
        subject - The message header subject.
        draft - The message header draft indication.
        attachments - The message header attachments, a vector of Reference objects.
        body - The message body.
        Returns:
        The newly added message.
        Throws:
        org.sakaiproject.exception.PermissionException - If the user does not have write permission to the channel.