Enum Class AccessTokenPermission

java.lang.Object
java.lang.Enum<AccessTokenPermission>
com.atlassian.bamboo.accesstoken.AccessTokenPermission
All Implemented Interfaces:
Serializable, Comparable<AccessTokenPermission>, Constable

public enum AccessTokenPermission extends Enum<AccessTokenPermission>
Permission that is granted to the access token.
  • Enum Constant Details

    • READ

      public static final AccessTokenPermission READ
      Grants read-only access to the token.
    • TRIGGER

      public static final AccessTokenPermission TRIGGER
      Grants permission to trigger builds and deployments in Bamboo.
    • USER

      public static final AccessTokenPermission USER
      Grants all the permissions that the granting user has.
  • Method Details

    • values

      public static AccessTokenPermission[] 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 AccessTokenPermission 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
    • forName

      @Nullable public static @Nullable AccessTokenPermission forName(@NotNull @NotNull String name)
      Return an access token permission type for the given name. Does a case-insensitive check.
      Parameters:
      name - name of the permission type
      Returns:
      the given permission or null if not found
    • getMask

      public int getMask()
      Bits that represents this permission. Must be unique so that two permissions never have the same bits set.
    • getDependencies

      public List<AccessTokenPermission> getDependencies()
      A list of permissions which must also be granted to grant this permission.

      This is not an effective list - to obtain a full list of dependent permissions, the result must be traversed and subsequent dependencies must be recursively included.