|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Interface for a repository of users. A repository represents a logical grouping of users, typically by common purpose. E.g. the users served by an email server or the members of a mailing list.
Field Summary | |
static String |
ROLE
The component role used by components implementing this service |
static String |
USER
|
Method Summary | |
void |
addUser(String name,
Object attributes)
Adds a user to the repository with the specified attributes. |
boolean |
addUser(User user)
Adds a user to the repository with the specified User object. |
boolean |
contains(String name)
Returns whether or not this user is in the repository |
boolean |
containsCaseInsensitive(String name)
Returns whether or not this user is in the repository. |
int |
countUsers()
Returns a count of the users in the repository. |
Object |
getAttributes(String name)
Deprecated. As of James 1.2.2 . Use the getUserByName method. |
String |
getRealName(String name)
Returns the user name of the user matching name on an equalsIgnoreCase basis. |
User |
getUserByName(String name)
Get the user object with the specified user name. |
User |
getUserByNameCaseInsensitive(String name)
Get the user object with the specified user name. |
Iterator |
list()
List users in repository. |
void |
removeUser(String name)
Removes a user from the repository |
boolean |
test(String name,
Object attributes)
Deprecated. As of James 1.2.2, use test(String name, String password) |
boolean |
test(String name,
String password)
Test if user with name 'name' has password 'password'. |
boolean |
updateUser(User user)
Update the repository with the specified user object. |
Field Detail |
public static final String ROLE
public static final String USER
Method Detail |
public boolean addUser(User user)
user
- the user to be added
public void addUser(String name, Object attributes)
name
- the name of the user to be addedattributes
- see decriptionpublic Object getAttributes(String name)
getUserByName
method.
public User getUserByName(String name)
name
- the name of the user to retrieve
public User getUserByNameCaseInsensitive(String name)
name
- the name of the user to retrieve
public String getRealName(String name)
name
- the name to case-correct
public boolean updateUser(User user)
public void removeUser(String name)
name
- the user to remove from the repositorypublic boolean contains(String name)
name
- the name to check in the repository
public boolean containsCaseInsensitive(String name)
name
- the name to check in the repository
public boolean test(String name, Object attributes)
test(String name, String password)
public boolean test(String name, String password)
name
- the name of the user to be testedpassword
- the password to be tested
public int countUsers()
public Iterator list()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |