Enum Class PullRequestOrder

java.lang.Object
java.lang.Enum<PullRequestOrder>
com.atlassian.bitbucket.pull.PullRequestOrder
All Implemented Interfaces:
Serializable, Comparable<PullRequestOrder>, Constable

public enum PullRequestOrder extends Enum<PullRequestOrder>
Specifies the order in which a list of results should be returned - multiple criteria can be applied.
See Also:
  • Enum Constant Details

    • OLDEST

      public static final PullRequestOrder OLDEST
      Indicates older pull requests should be shown before newer ones
    • NEWEST

      public static final PullRequestOrder NEWEST
      Indicates newer pull requests should be shown before older ones
    • DRAFT_STATUS

      public static final PullRequestOrder DRAFT_STATUS
      Indicates pull requests should be shown in an order based on status. For PRs where the draft status is the same, NEWEST order will be applied.
      Since:
      8.18
    • PARTICIPANT_STATUS

      public static final PullRequestOrder PARTICIPANT_STATUS
      Indicates pull requests should be shown in an order based on status. For PRs where the participant has the same status, NEWEST order will be applied.
      Since:
      4.4
      See Also:
    • CLOSED_DATE

      public static final PullRequestOrder CLOSED_DATE
      Indicates pull requests will be ordered by closed timestamp in descending order. Specifically open pull requests will be shown before closed ones, then most recently closed pull requests. Where pull requests are still in the open state newer pull requests are be shown before older ones (i.e. last updated descending).
      Since:
      4.10
  • Method Details

    • values

      public static PullRequestOrder[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static PullRequestOrder valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • fromString

      public static PullRequestOrder fromString(@Nullable String stringValue, @Nullable PullRequestOrder defaultValue)
      Coerces a string to a PullRequestOrder or returns the supplied default value if this is not possible.
      Parameters:
      stringValue - the string value of the pull request
      defaultValue - the default value to return if coercion is not possible
      Returns:
      the corresponding PullRequestOrder instance
    • getDefaultOrder

      @Nonnull public static PullRequestOrder getDefaultOrder()
      Returns:
      NEWEST