public class SimpleUser extends Object implements User<Permission,Role<Permission>>
| Constructor and Description |
|---|
SimpleUser() |
| Modifier and Type | Method and Description |
|---|---|
void |
addRole(Role<Permission> role)
Adds the given role to the user.
|
String |
getId()
Returns the field
id. |
String |
getPw()
Returns the field
password. |
Set<Role<Permission>> |
getRoles()
Returns the field
roles. |
String |
getUsername()
Returns the field
username. |
Boolean |
isActive()
Checks if this User is active.
|
Boolean |
isLocked()
Returns the field
lock. |
boolean |
removeRole(Role<Permission> role)
Removes the given role from the user.
|
void |
setActive(Boolean active)
Sets the active flag.
|
void |
setId(String id)
Sets the field
id. |
void |
setLocked(Boolean lock)
Sets the field
lock. |
void |
setPw(String password)
Sets the field
password. |
void |
setRoles(Set<Role<Permission>> roles)
Sets the field
roles. |
void |
setUsername(String username)
Sets the field
username. |
public String getId()
id.getId in interface User<Permission,Role<Permission>>id.User.getId()public String getUsername()
username.getUsername in interface User<Permission,Role<Permission>>username.User.getUsername()public Boolean isLocked()
lock.isLocked in interface User<Permission,Role<Permission>>lock.User.isLocked()public void setId(String id)
id.setId in interface User<Permission,Role<Permission>>id - The id to setUser.setId(java.lang.String)public void setLocked(Boolean lock)
lock.setLocked in interface User<Permission,Role<Permission>>lock - The lock to setpublic void setUsername(String username)
username.setUsername in interface User<Permission,Role<Permission>>username - The username to setUser.setUsername(java.lang.String)public String getPw()
password.getPw in interface User<Permission,Role<Permission>>password.User.getPw()public void setPw(String password)
password.setPw in interface User<Permission,Role<Permission>>password - The password to setpublic Boolean isActive()
UserisActive in interface User<Permission,Role<Permission>>public void setActive(Boolean active)
UsersetActive in interface User<Permission,Role<Permission>>active - the new active flag.public void addRole(Role<Permission> role)
UseraddRole in interface User<Permission,Role<Permission>>role - the rolepublic Set<Role<Permission>> getRoles()
Userroles.getRoles in interface User<Permission,Role<Permission>>roles.public boolean removeRole(Role<Permission> role)
UserremoveRole in interface User<Permission,Role<Permission>>role - the rolepublic void setRoles(Set<Role<Permission>> roles)
Userroles.setRoles in interface User<Permission,Role<Permission>>roles - The roles to setCopyright © 2007–2015 Alpha Ro Group UG (haftungsbeschrÀngt). All rights reserved.