public class MgnlUser extends AbstractUser implements User, Serializable
MgnlUserManager.getUser(String)
or similar methods instead.Constructor and Description |
---|
MgnlUser(String name,
String realm,
Collection<String> directGroups,
Collection<String> directRoles,
Map<String,String> properties)
Deprecated.
since 5.5.5. Please use
MgnlUser(String, String, Collection, Collection, Map, String, String, Collection, Collection) instead. |
MgnlUser(String name,
String realm,
Collection<String> directGroups,
Collection<String> directRoles,
Map<String,String> properties,
String path,
String uuid)
Deprecated.
since 5.5.5. Please use
MgnlUser(String, String, Collection, Collection, Map, String, String, Collection, Collection) instead. |
MgnlUser(String name,
String realm,
Collection<String> directGroups,
Collection<String> directRoles,
Map<String,String> properties,
String path,
String uuid,
Collection<String> allGroups,
Collection<String> allRoles)
This constructor is mainly used by
MgnlUserManager or by custom extensions of this object. |
Modifier and Type | Method and Description |
---|---|
protected String |
decodePassword(String encodedPassword)
Deprecated.
Since 4.5.8. Password is now encoded by BCrypt and therefore cannot be decoded.
|
Collection<String> |
getAllGroups()
Get all groups this user belongs to, collected recursively including supergroups.
|
Collection<String> |
getAllRoles()
Get all roles assigned to this user, collected recursively including groups and supergroups.
|
int |
getFailedLoginAttempts() |
Collection<String> |
getGroups()
Get groups that are directly assigned to the user.
|
String |
getIdentifier()
Gets user identifier.
|
String |
getLanguage() |
String |
getName() |
String |
getPassword() |
String |
getPath() |
String |
getProperty(String propertyName)
Gets an arbitrary property from this user.
|
String |
getRealm() |
Calendar |
getReleaseTime() |
Collection<String> |
getRoles()
Get roles that are directly assigned to the user.
|
String |
getUuid()
Deprecated.
since 4.5.1, use
getIdentifier() instead |
boolean |
hasRole(String roleName)
Is this user in a specified role?
|
boolean |
inGroup(String groupName)
Is this user in a specified group?
|
boolean |
isEnabled()
Returns false if the user was explicitly disabled.
|
void |
setLastAccess()
Deprecated.
since 4.5, use
UserManager.updateLastAccessTimestamp(User) instead |
void |
setPath(String path)
Deprecated.
|
void |
setProperty(String propertyName,
String value)
Deprecated.
since 4.5, use
UserManager instead |
String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addGroup, addRole, removeGroup, removeRole, setEnabled
public MgnlUser(String name, String realm, Collection<String> directGroups, Collection<String> directRoles, Map<String,String> properties, String path, String uuid, Collection<String> allGroups, Collection<String> allRoles)
MgnlUserManager
or by custom extensions of this object.
If you extend MgnlUser, chances are you need to provide your own MgnlUserManager
as well.@Deprecated public MgnlUser(String name, String realm, Collection<String> directGroups, Collection<String> directRoles, Map<String,String> properties, String path, String uuid)
MgnlUser(String, String, Collection, Collection, Map, String, String, Collection, Collection)
instead.@Deprecated public MgnlUser(String name, String realm, Collection<String> directGroups, Collection<String> directRoles, Map<String,String> properties)
MgnlUser(String, String, Collection, Collection, Map, String, String, Collection, Collection)
instead.public boolean inGroup(String groupName)
User
public boolean isEnabled()
User
public boolean hasRole(String roleName)
User
public int getFailedLoginAttempts()
public Calendar getReleaseTime()
public String getName()
public String getPassword()
getPassword
in interface User
@Deprecated protected String decodePassword(String encodedPassword)
public String getLanguage()
getLanguage
in interface User
public String getProperty(String propertyName)
User
getProperty
in interface User
public Collection<String> getGroups()
User
public Collection<String> getAllGroups()
User
getAllGroups
in interface User
public Collection<String> getRoles()
User
public Collection<String> getAllRoles()
User
getAllRoles
in interface User
public String getPath()
@Deprecated public void setPath(String path)
public String getRealm()
@Deprecated public void setLastAccess()
UserManager.updateLastAccessTimestamp(User)
instead@Deprecated public void setProperty(String propertyName, String value)
UserManager
insteadUser
setProperty
in interface User
public String getIdentifier()
User
getIdentifier
in interface User
@Deprecated public String getUuid()
getIdentifier()
insteadCopyright © 2003–2020 Magnolia International Ltd.. All rights reserved.