Interface IMailingList

All Superinterfaces:
IDeletionSupport, IElement, IProtocolSupport, ISecuritySupport, Serializable

public interface IMailingList extends IElement, IProtocolSupport, IDeletionSupport, ISecuritySupport
This interface represents a mailing list.
Author:
fsalque
  • Method Details

    • getName

      String getName()
      Returns:
      the name of the mailing list.
    • setName

      void setName(String name)
      Sets the name of the mailing list.
      Parameters:
      name - the new name to set.
    • getLabel

      String getLabel()
      Returns:
      the label of the mailing list.
    • setLabel

      void setLabel(String label)
      Sets the label of the mailing list.
      Parameters:
      label - the new label to set.
    • getDescription

      String getDescription()
      Returns:
      the description of the mailing list.
    • setDescription

      void setDescription(String description)
      Sets the description of the mailing list.
      Parameters:
      description - the new description to set.
    • getType

      int getType()
      Gets the mailing list type.
      Returns:
      the type of the mailing list.
    • setType

      void setType(int type)
      Sets the type of the mailing list.
      Parameters:
      type - the type to set.
    • getCreator

      IUser getCreator()
      Gets the creator of the mailing list.
      Returns:
      A IUser the creator of the mailing list.
    • getCreationDate

      Date getCreationDate()
      Gets the creation date of the mailing list.
      Returns:
      the creation date of the mailing list.
    • getOrganization

      IOrganization getOrganization()
      Gets the organization object.
      Returns:
      A IOrganization object.
    • setOrganization

      void setOrganization(IOrganization organization)
      Sets the mailing list organization.
      Parameters:
      organization - the new IOrganization to set.
    • getUsers

      Collection<? extends IUser> getUsers()
      Gets all the users with an ACTIVE status.
      Returns:
      a java.util.Collection of IUser objects.
    • getUnsubscribedUsers

      Collection<? extends IUser> getUnsubscribedUsers()
      Gets all the users with an INACTIVE status.
      Returns:
      a Collection object of IUser.
    • subscribeUser

      void subscribeUser(IContext context, IUser user)
      Subscribes a user to the mailing list.
      Parameters:
      context - the execution context.
      user - the IUser to be subscribed.
      Throws:
      PortalModuleException - default module exception.
    • unsubscribeUser

      void unsubscribeUser(IUser user)
      Unsubscribes a user to the mailing list.
      Parameters:
      user - the IUser to be unsubscribed.
      Throws:
      PortalModuleException - default module exception.
    • removeUser

      void removeUser(IUser user)
      Permanently removes a user from the mailing list
      Parameters:
      user - the IUser to be removed.
      Throws:
      PortalModuleException - default module exception.
    • removeUsers

      void removeUsers()
      Permanently removes all users from the mailing list
      Throws:
      PortalModuleException - default module exception.
    • getGroups

      Collection<? extends IGroup> getGroups()
      Gets all the groups.
      Returns:
      a java.util.Collection of IGroup objects.
    • addGroup

      void addGroup(IContext context, IGroup group)
      Adds a group to the mailing list.
      Parameters:
      context - the execution context.
      group - the IGroup to be added.
      Throws:
      PortalModuleException - default module exception.
    • removeGroup

      void removeGroup(IGroup group)
      Removes a group from the mailing list.
      Parameters:
      group - the IGroup to be removed.
      Throws:
      PortalModuleException - default module exception.
    • removeGroups

      void removeGroups()
      Removes all groups from the mailing list.
      Throws:
      PortalModuleException - default module exception.
    • getProfiles

      Collection<? extends IProfile> getProfiles()
      Gets all the profiles.
      Returns:
      a java.util.Collection of IProfile objects.
    • addProfile

      void addProfile(IContext context, IProfile profile)
      Adds a profile to the mailing list.
      Parameters:
      context - the execution context.
      profile - the IProfile to be added.
      Throws:
      PortalModuleException - default module exception.
    • removeProfile

      void removeProfile(IProfile profile)
      Removes a profile from the mailing list.
      Parameters:
      profile - the IProfile to be removed.
      Throws:
      PortalModuleException - default module exception.
    • removeProfiles

      void removeProfiles()
      Removes all profiles from the mailing list.
      Throws:
      PortalModuleException - default module exception.
    • getAllUsers

      Collection<? extends IUser> getAllUsers()
      Returns:
      all users who are in groups and the profiles
    • getAllEmails

      Collection<String> getAllEmails()
      Returns:
      all users' mail who are in groups and the profiles
    • getEmails

      Collection<String> getEmails()
      Gets all the emails.
      Returns:
      a java.util.Collection of java.lang.String objects.
    • addEmail

      void addEmail(IContext context, String email) throws PortalModuleException
      Adds an email address to the mailing list.
      Parameters:
      context - the execution context.
      email - the email address to be added.
      Throws:
      PortalModuleException - default module exception.
    • removeEmail

      void removeEmail(String email)
      Removes an email address from the mailing list.
      Parameters:
      email - the email address to be removed.
      context - the execution context.
      Throws:
      PortalModuleException - default module exception.
    • removeEmails

      void removeEmails()
      Removes all emails from the mailing list.
      Parameters:
      context - the execution context.
      Throws:
      PortalModuleException - default module exception.
    • setLink

      void setLink(IProtocolSupport link)
      Sets the resource associated with the mailing list.
      Parameters:
      link - IProtocolSupport to associate with the mailing list.
    • getLink

      Gets the resource associated with the mailing list.
      Returns:
      the IProtocolSupport associated with the mailing list.
      Throws:
      PortalModuleException - default module exception.