public final class Role extends Object implements Comparable
Permissions.| Modifier and Type | Field and Description |
|---|---|
static String |
GLOBAL_ROLE_PATTERN |
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(Object o)
Compare role names.
|
String |
getName()
Getter for the role name.
|
Pattern |
getPattern()
Getter for the regexp pattern.
|
Set<hudson.security.Permission> |
getPermissions()
Getter for the
Permissions set. |
Boolean |
hasAnyPermission(Set<hudson.security.Permission> permissions)
Checks if the role holds any of the given
Permission. |
Boolean |
hasPermission(hudson.security.Permission permission)
Checks if the role holds the given
Permission. |
public static final String GLOBAL_ROLE_PATTERN
public final String getName()
public final Pattern getPattern()
public final Set<hudson.security.Permission> getPermissions()
Permissions set.Permissions setpublic final Boolean hasPermission(hudson.security.Permission permission)
Permission.permission - The permission you want to checkpublic final Boolean hasAnyPermission(Set<hudson.security.Permission> permissions)
Permission.permissions - A Permissions setPermissionspublic int compareTo(Object o)
Used to sort the set.
compareTo in interface Comparableo - The object you want to compare this instance toCopyright © 2004-2013. All Rights Reserved.