Enum Class RefOrder

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

public enum RefOrder extends Enum<RefOrder>
Defines orderings which can be applied when retrieving references. The actual approach for applying an ordering is not established or guaranteed by this enumeration; it may vary by SCM implementation or Ref type.
  • Enum Constant Details

    • ALPHABETICAL

      public static final RefOrder ALPHABETICAL
      Return references in ascending alphabetical order.
    • MODIFICATION

      public static final RefOrder MODIFICATION
      Return references in descending modification order, with the most recently-modified references returned first.
  • Method Details

    • values

      public static RefOrder[] 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 RefOrder 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
    • fromValueOrNull

      @Nullable public static RefOrder fromValueOrNull(@Nullable String order)
      Parses the provided order, if possible. If the order provided is null, empty or does not match a known order, null is returned.
      Parameters:
      order - the order to parse
      Returns:
      the parsed order, or null if it cannot be parsed