|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.cargo.container.property.User
public final class User
Represent an authenticating user for the Servlet container.
Constructor Summary | |
---|---|
User()
|
Method Summary | |
---|---|
void |
addRole(String role)
|
void |
addRoles(List roles)
|
static Map |
createRoleMap(List users)
Create a user map indexed on the roles. |
boolean |
equals(Object userObject)
|
String |
getName()
|
String |
getPassword()
|
List |
getRoles()
|
int |
hashCode()
|
protected static List |
parseRoles(String rolesAsString)
Parse roles defined as a list in the format "role1,role2,...,roleN". |
protected static User |
parseUser(String userAsString)
Parse a user defined in the format "name:pwd:role1,...roleN". |
static List |
parseUsers(String usersAsString)
Parse a string representing the users (see ServletPropertySet.USERS . |
void |
setName(String name)
|
void |
setPassword(String password)
Sets the authenticated user password. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public User()
Method Detail |
---|
public void setName(String name)
name
- the user namepublic String getName()
public void setPassword(String password)
password
- the user passwordpublic String getPassword()
public void addRole(String role)
role
- a role attached to this userpublic void addRoles(List roles)
roles
- a list of roles attached to this userpublic List getRoles()
public boolean equals(Object userObject)
equals
in class Object
Object.equals(java.lang.Object)
public int hashCode()
hashCode
in class Object
Object.hashCode()
public static List parseUsers(String usersAsString)
ServletPropertySet.USERS
.
usersAsString
- the string representing the users
User
objectsprotected static User parseUser(String userAsString)
userAsString
- the user defines as a string
protected static List parseRoles(String rolesAsString)
rolesAsString
- the roles defined as a string
public static Map createRoleMap(List users)
users
- list of User
for which to extract roles from
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |