public interface RoleService
| Modifier and Type | Method and Description |
|---|---|
Role |
defineRole(Role role)
Ensures the given Role exists based on the unique name.
|
Role |
defineRole(String authority,
String name,
Collection<String> permissions)
Deprecated.
|
Role |
defineRole(String authority,
String name,
String description,
Collection<String> permissions)
Ensures a Role with the specified permissions exists.
|
void |
delete(Role role)
Delete the given Role entity.
|
Role |
getRole(String authority)
Get the Role entity with the given authority.
|
Collection<Role> |
getRoles()
Get all defined Roles.
|
Role |
save(Role role)
Save the given Role entity.
|
@Deprecated Role defineRole(String authority, String name, Collection<String> permissions)
authority - Unique authority of the Role entity.name - Descriptive name of the Role.permissions - Permission names to apply to the role.Role defineRole(String authority, String name, String description, Collection<String> permissions)
authority - Unique authority of the Role entity.name - Descriptive name of the Role.description - Description of what the role should be used for.permissions - Permission names to apply to the role.Role defineRole(Role role)
role - Role entity that should exist.Collection<Role> getRoles()
Role getRole(String authority)
authority - Unique authority of the Role.void delete(Role role)
role - Entity to delete.Copyright © 2020. All rights reserved.