public class RoleLDAPStorageMapper.LDAPRoleMappingsUserDelegate extends UserModelDelegate
UserModel.RequiredAction, UserModel.UserRemovedEvent
delegate
EMAIL, FIRST_NAME, GROUPS, INCLUDE_SERVICE_ACCOUNT, LAST_NAME, LOCALE, SEARCH, USERNAME
Constructor and Description |
---|
LDAPRoleMappingsUserDelegate(RealmModel realm,
UserModel user,
LDAPObject ldapUser) |
Modifier and Type | Method and Description |
---|---|
void |
deleteRoleMapping(RoleModel role)
Removes the given role mapping from this object.
|
Set<RoleModel> |
getClientRoleMappings(ClientModel client)
Returns set of client roles that are directly set to this object for the given client.
|
protected Set<RoleModel> |
getLDAPRoleMappingsConverted() |
Set<RoleModel> |
getRealmRoleMappings()
Returns set of realm roles that are directly set to this object.
|
Set<RoleModel> |
getRoleMappings()
Returns set of all role (both realm all client) that are directly set to this object.
|
void |
grantRole(RoleModel role)
Grants the given role to this object.
|
boolean |
hasRole(RoleModel role)
Returns
true if this object is directly or indirectly assigned the given role, false otherwise. |
addRequiredAction, addRequiredAction, equals, getAttribute, getAttributes, getCreatedTimestamp, getDelegate, getEmail, getFederationLink, getFirstAttribute, getFirstName, getGroups, getId, getLastName, getRequiredActions, getServiceAccountClientLink, getUsername, hashCode, isEmailVerified, isEnabled, isMemberOf, joinGroup, leaveGroup, removeAttribute, removeRequiredAction, removeRequiredAction, setAttribute, setCreatedTimestamp, setEmail, setEmailVerified, setEnabled, setFederationLink, setFirstName, setLastName, setServiceAccountClientLink, setSingleAttribute, setUsername
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
getGroups, getGroups, getGroupsCount, getGroupsCountByNameContaining
public LDAPRoleMappingsUserDelegate(RealmModel realm, UserModel user, LDAPObject ldapUser)
public Set<RoleModel> getRealmRoleMappings()
RoleMapperModel
getRealmRoleMappings
in interface RoleMapperModel
getRealmRoleMappings
in class UserModelDelegate
public Set<RoleModel> getClientRoleMappings(ClientModel client)
RoleMapperModel
getClientRoleMappings
in interface RoleMapperModel
getClientRoleMappings
in class UserModelDelegate
client
- Client to get the roles forpublic boolean hasRole(RoleModel role)
RoleMapperModel
true
if this object is directly or indirectly assigned the given role, false
otherwise.
For example, true
is returned for hasRole(R) if:
hasRole
in interface RoleMapperModel
hasRole
in class UserModelDelegate
public void grantRole(RoleModel role)
RoleMapperModel
grantRole
in interface RoleMapperModel
grantRole
in class UserModelDelegate
public Set<RoleModel> getRoleMappings()
RoleMapperModel
getRoleMappings
in interface RoleMapperModel
getRoleMappings
in class UserModelDelegate
public void deleteRoleMapping(RoleModel role)
RoleMapperModel
deleteRoleMapping
in interface RoleMapperModel
deleteRoleMapping
in class UserModelDelegate
role
- Role to removeCopyright © 2020 JBoss by Red Hat. All rights reserved.