Class CloneOptionConfiguration

java.lang.Object
com.atlassian.jira.issue.customfields.CloneOptionConfiguration

@PublicApi public final class CloneOptionConfiguration extends Object
Configures a clone option for a given custom field in the context of an issue. A clone option configuration controls whether an option is displayed on the clone dialog, the label displayed when the option is displayed, and the option's initial state, i.e. whether it's selected by default.
Since:
7.2
  • Field Details

    • DO_NOT_DISPLAY

      public static final CloneOptionConfiguration DO_NOT_DISPLAY
      An instance of CloneOptionConfiguration that indicates the clone option should not be displayed on the clone dialog.
  • Method Details

    • shouldDisplayOption

      public boolean shouldDisplayOption()
      Returns:
      A boolean that indicates whether this option should be displayed on the clone dialog.
    • getOptionLabel

      @Nonnull public String getOptionLabel()
      Returns:
      Label to be displayed for this clone option.
    • isOptionSelectedByDefault

      public boolean isOptionSelectedByDefault()
      Returns:
      A boolean that indicates whether this option is selected by default.
    • withOptionLabel

      @Nonnull public static CloneOptionConfiguration withOptionLabel(String optionLabel)
      Creates an instance of CloneOptionConfiguration to represent a clone option that gets displayed in the clone dialog with the specified label. This clone option will not be selected by default.
      Parameters:
      optionLabel - Label of clone option
      Returns:
      An instance of CloneOptionConfiguration to represent a clone option that gets displayed in the clone dialog with the specified label.
    • selectOptionByDefault

      @Nonnull public CloneOptionConfiguration selectOptionByDefault()
      Creates an instance of CloneOptionConfiguration to represent a clone option that gets displayed in the clone dialog with the same label as this option's label and is selected by default.
      Returns:
      An instance of CloneOptionConfiguration to represent a clone option that gets displayed in the clone dialog with the same label as this option's label and is selected by default.