Class AbstractNotificationType

java.lang.Object
com.atlassian.jira.notification.type.AbstractNotificationType
All Implemented Interfaces:
NotificationType
Direct Known Subclasses:
AllWatchers, ComponentLead, CurrentAssignee, CurrentReporter, ErrorNotificationType, GroupCFValue, GroupDropdown, ProjectLead, RemoteUser, SingleEmailAddress, SingleUser, TypeForTesting, TypeForTesting2, UserCFValue

public abstract class AbstractNotificationType extends Object implements NotificationType
  • Constructor Details

    • AbstractNotificationType

      public AbstractNotificationType()
  • Method Details

    • getType

      public String getType()
      Description copied from interface: NotificationType
      Type identifier (currently unused).
      Specified by:
      getType in interface NotificationType
      Returns:
      Eg. "group"
    • doValidation

      public boolean doValidation(String key, Map parameters)
      Description copied from interface: NotificationType
      Validate the configuration (the argument in NotificationType.getRecipients(com.atlassian.jira.event.issue.IssueEvent, String)) when it is entered in the "Add Notification" page. For instance, a group notification type might check if the entered group exists.
      Specified by:
      doValidation in interface NotificationType
      Parameters:
      key - Key of relevant value in parameters
      parameters - HTML form parameters (only the keyed entry is relevant).
      Returns:
      Whether the entered value is valid for this type.
    • getArgumentDisplay

      public String getArgumentDisplay(String argument)
      Description copied from interface: NotificationType
      Obtains the user-friendly display for the argument. For example, returns a username for a key.
      Specified by:
      getArgumentDisplay in interface NotificationType
      Parameters:
      argument - Raw configuration value
      Returns:
      Formatted configuration value.
    • getArgumentValue

      public String getArgumentValue(String displayValue)
      Description copied from interface: NotificationType
      Obtains the raw parameter value to save for the given user entry user-friendly display value. For example, the user picker displays a username, but this needs to be stored in the configuration parameter as the user's key, instead.
      Specified by:
      getArgumentValue in interface NotificationType
      Parameters:
      displayValue - Value entered into the form (username, for example)
      Returns:
      raw configuration value.