Class BambooPermission
- java.lang.Object
-
- com.atlassian.bamboo.security.acegi.acls.BambooPermission
-
- All Implemented Interfaces:
Serializable
,org.acegisecurity.acls.Permission
public class BambooPermission extends Object implements org.acegisecurity.acls.Permission, Serializable
Notes: - permissions name strings should not contain '_' character to avoid interfering with UI field id creation- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static BambooPermission
ADMINISTRATION
static Set<BambooPermission>
ALL_PERMISSIONS
static BambooPermission
APPROVE_RELEASE
static BambooPermission
BUILD
static BambooPermission
CLONE
static BambooPermission
CREATE
static BambooPermission
CREATE_REPOSITORY
static BambooPermission
DELETE
static com.google.common.collect.ImmutableList<BambooPermission>
PLAN_RELATED_PERMISSIONS
Deprecated.static BambooPermission
READ
static BambooPermission
RESTRICTEDADMINISTRATION
static BambooPermission
SIGN_UP
static BambooPermission
SOX_COMPLIANCE
static BambooPermission
VIEW_CONFIGURATION
static BambooPermission
WRITE
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static org.acegisecurity.acls.Permission
buildFromMask(int mask)
Dynamically creates aCumulativePermission
orBambooPermission
representing the active bits in the passed mask.static org.acegisecurity.acls.Permission[]
buildFromMask(int[] inputMasks)
static @NotNull org.acegisecurity.acls.Permission
buildFromName(String name)
static org.acegisecurity.acls.Permission[]
buildFromName(String[] names)
static BambooPermission
convertToBambooPermission(org.acegisecurity.acls.Permission permission)
static @Nullable String
determineNameFromPermission(org.acegisecurity.acls.Permission permission)
Determine the name of the permission based on the bit mask.boolean
equals(Object arg0)
int
getMask()
String
getName()
String
getPattern()
static @NotNull com.google.common.collect.ImmutableList<BambooPermission>
getPlanPermissionsList()
Deprecated.since 6.2 usePlanPermissionsService.supportedPermissions()
int
hashCode()
static boolean
isGlobalPermissionGrantedForRestrictedAdmin(org.acegisecurity.acls.Permission permission)
Check if global permission is granted for restricted adminString
toString()
-
-
-
Field Detail
-
READ
public static final BambooPermission READ
-
WRITE
public static final BambooPermission WRITE
-
CREATE
public static final BambooPermission CREATE
-
DELETE
public static final BambooPermission DELETE
-
ADMINISTRATION
public static final BambooPermission ADMINISTRATION
-
SIGN_UP
public static final BambooPermission SIGN_UP
-
BUILD
public static final BambooPermission BUILD
-
CLONE
public static final BambooPermission CLONE
-
RESTRICTEDADMINISTRATION
public static final BambooPermission RESTRICTEDADMINISTRATION
-
SOX_COMPLIANCE
public static final BambooPermission SOX_COMPLIANCE
-
CREATE_REPOSITORY
public static final BambooPermission CREATE_REPOSITORY
-
VIEW_CONFIGURATION
public static final BambooPermission VIEW_CONFIGURATION
-
APPROVE_RELEASE
public static final BambooPermission APPROVE_RELEASE
-
PLAN_RELATED_PERMISSIONS
@Deprecated public static final com.google.common.collect.ImmutableList<BambooPermission> PLAN_RELATED_PERMISSIONS
Deprecated.
-
ALL_PERMISSIONS
public static final Set<BambooPermission> ALL_PERMISSIONS
-
-
Method Detail
-
determineNameFromPermission
@Nullable public static @Nullable String determineNameFromPermission(org.acegisecurity.acls.Permission permission)
Determine the name of the permission based on the bit mask. TODO: Do we still need it? We should be operating on BambooPermission objects instead of Strings
-
getPlanPermissionsList
@NotNull @Deprecated public static @NotNull com.google.common.collect.ImmutableList<BambooPermission> getPlanPermissionsList()
Deprecated.since 6.2 usePlanPermissionsService.supportedPermissions()
Returns collection of all possible collections for plan. Has to be updated, when new permission is added- Returns:
- collection of all possible permissions for plan
-
buildFromMask
public static org.acegisecurity.acls.Permission buildFromMask(int mask)
Dynamically creates aCumulativePermission
orBambooPermission
representing the active bits in the passed mask.- Parameters:
mask
- to build- Returns:
- a Permission representing the requested object
-
buildFromMask
public static org.acegisecurity.acls.Permission[] buildFromMask(int[] inputMasks)
-
buildFromName
@NotNull public static @NotNull org.acegisecurity.acls.Permission buildFromName(String name)
-
buildFromName
public static org.acegisecurity.acls.Permission[] buildFromName(String[] names)
-
isGlobalPermissionGrantedForRestrictedAdmin
public static boolean isGlobalPermissionGrantedForRestrictedAdmin(org.acegisecurity.acls.Permission permission)
Check if global permission is granted for restricted admin
-
convertToBambooPermission
public static BambooPermission convertToBambooPermission(org.acegisecurity.acls.Permission permission)
-
getMask
public int getMask()
- Specified by:
getMask
in interfaceorg.acegisecurity.acls.Permission
-
getName
public String getName()
-
getPattern
public String getPattern()
- Specified by:
getPattern
in interfaceorg.acegisecurity.acls.Permission
-
-