|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface PermissionService
Manages permissions in Deployit.
| Method Summary | |
|---|---|
void |
checkMyPermission(java.lang.String permission,
java.lang.String id)
Deprecated. Use GET /security/check. |
java.util.Map<java.lang.String,java.util.Collection<java.lang.String>> |
getGrantedPermissions(java.lang.String role)
Gets all the permissions granted to a role. |
java.util.Map<java.lang.String,java.util.Collection<java.lang.String>> |
getMyGrantedPermissions()
Gets all the permissions granted to the logged in user. |
void |
grant(java.lang.String permission,
java.lang.String id,
java.lang.String role)
Grants a permission to a role on a CI. |
boolean |
isGranted(java.lang.String permission,
java.lang.String id,
java.lang.String role)
Checks if a permission is granted to a role on a CI. |
boolean |
isGrantedToMe(java.lang.String permission,
java.lang.String id)
Checks if the currently logged in user has a certain permission on a CI. |
void |
revoke(java.lang.String permission,
java.lang.String id,
java.lang.String role)
Revokes the permission of a role on a CI. |
| Method Detail |
|---|
java.util.Map<java.lang.String,java.util.Collection<java.lang.String>> getGrantedPermissions(java.lang.String role)
role - the role to get the permissions for.
java.util.Map<java.lang.String,java.util.Collection<java.lang.String>> getMyGrantedPermissions()
boolean isGranted(java.lang.String permission,
java.lang.String id,
java.lang.String role)
permission - the name of the permission to check.id - the path of the CI to check the permission on.role - the role to which the permission should be granted.
true if granted.
void grant(java.lang.String permission,
java.lang.String id,
java.lang.String role)
permission - the name of the permission to grant.id - the path of the CI to grant the permission on.role - the role to which the permission should be granted.
void revoke(java.lang.String permission,
java.lang.String id,
java.lang.String role)
permission - the name of the permission to revoke.id - the path of the CI to revoke the permission from.role - the role from which the permission should be revoked.
@Deprecated
void checkMyPermission(java.lang.String permission,
java.lang.String id)
GET /security/check.
GET /security/check.
Checks if the currently logged in user has a certain permission on a CI. If the user does not have this permission, error code 403 is returned.
permission - the name of the permission to check.id - the path of the CI to check the permission on.
boolean isGrantedToMe(java.lang.String permission,
java.lang.String id)
permission - the name of the permission to check.id - the path of the CI to check the permission on.
true if the user has this permission; false otherwise.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||