@Profile(value="ldap") @Component(value="domainUserRepository") public class DomainUserRepositoryImpl extends Object implements DomainUserRepository
| Constructor and Description |
|---|
DomainUserRepositoryImpl(DomainControllerProperties properties,
org.springframework.beans.factory.ObjectProvider<org.bremersee.data.ldaptive.LdaptiveTemplate> ldapTemplateProvider,
DomainRepository domainRepository,
DomainGroupRepository domainGroupRepository)
Instantiates a new domain user repository.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
delete(String userName)
Delete user.
|
boolean |
exists(String userName)
Check whether user exists or not.
|
Stream<org.bremersee.dccon.model.DomainUser> |
findAll(String query)
Find all users.
|
Optional<byte[]> |
findAvatar(String userName,
org.bremersee.dccon.model.AvatarDefault avatarDefault,
Integer size)
Find avatar.
|
Optional<org.bremersee.dccon.model.DomainUser> |
findOne(String userName)
Find user by name.
|
org.bremersee.dccon.model.DomainUser |
save(org.bremersee.dccon.model.DomainUser domainUser,
Boolean updateGroups)
Save domain user.
|
void |
savePassword(String userName,
String newPassword)
Save password.
|
void |
setDomainUserLdapMapper(org.bremersee.data.ldaptive.LdaptiveEntryMapper<org.bremersee.dccon.model.DomainUser> domainUserLdapMapper)
Sets domain user ldap mapper.
|
public DomainUserRepositoryImpl(DomainControllerProperties properties, org.springframework.beans.factory.ObjectProvider<org.bremersee.data.ldaptive.LdaptiveTemplate> ldapTemplateProvider, DomainRepository domainRepository, DomainGroupRepository domainGroupRepository)
properties - the propertiesldapTemplateProvider - the ldap template providerdomainRepository - the domain repositorydomainGroupRepository - the domain group repositorypublic void setDomainUserLdapMapper(org.bremersee.data.ldaptive.LdaptiveEntryMapper<org.bremersee.dccon.model.DomainUser> domainUserLdapMapper)
domainUserLdapMapper - the domain user ldap mapperpublic Stream<org.bremersee.dccon.model.DomainUser> findAll(String query)
DomainUserRepositoryfindAll in interface DomainUserRepositoryquery - the querypublic Optional<org.bremersee.dccon.model.DomainUser> findOne(String userName)
DomainUserRepositoryfindOne in interface DomainUserRepositoryuserName - the user namepublic Optional<byte[]> findAvatar(String userName, org.bremersee.dccon.model.AvatarDefault avatarDefault, Integer size)
DomainUserRepositoryfindAvatar in interface DomainUserRepositoryuserName - the user nameavatarDefault - the avatar defaultsize - the sizepublic boolean exists(String userName)
DomainUserRepositoryexists in interface DomainUserRepositoryuserName - the user nametrue if the user exists, otherwise falsepublic org.bremersee.dccon.model.DomainUser save(org.bremersee.dccon.model.DomainUser domainUser,
Boolean updateGroups)
DomainUserRepositorysave in interface DomainUserRepositorydomainUser - the domain userupdateGroups - specifies whether the groups should also be updated or not (default is
false)public void savePassword(String userName, String newPassword)
DomainUserRepositorysavePassword in interface DomainUserRepositoryuserName - the user namenewPassword - the new passwordpublic boolean delete(String userName)
DomainUserRepositorydelete in interface DomainUserRepositoryuserName - the user nametrue if the user was removed; false if the user didn't existCopyright © 2020 bremersee.org. All rights reserved.