com.atlassian.user
Interface UserManager

All Superinterfaces:
EntityManager
All Known Implementing Classes:
CachingUserManager, DelegatingListUserManager, HibernateUserManager, MemoryUserManager, MemoryUserManagerReadOnly, OSUUserManager, ReadOnlyUserManager

public interface UserManager
extends EntityManager


Method Summary
 void alterPassword(User user, java.lang.String plainTextPass)
          Encrypts the plain password, sets it on the user, and saves the user.
 User createUser(java.lang.String username)
           
 User getUser(java.lang.String username)
           
 Pager getUserNames()
           
 Pager getUsers()
           
 boolean isReadOnly(User user)
           
 void removeUser(User user)
           
 void saveUser(User user)
           
 
Methods inherited from interface com.atlassian.user.EntityManager
getIdentifier, getRepository, isCreative
 

Method Detail

getUsers

public Pager getUsers()
               throws EntityException
Returns:
a Pager holding all users being managed.
Throws:
EntityException

getUserNames

public Pager getUserNames()
                   throws EntityException
Returns:
a Pager holding the names of all users being managed.
Throws:
EntityException

getUser

public User getUser(java.lang.String username)
             throws EntityException
Returns:
- a null or a User if one could be found.
Throws:
EntityException - - representing a system error.

createUser

public User createUser(java.lang.String username)
                throws EntityException
Returns:
a User object.
Throws:
EntityException - - representing a system error
java.lang.UnsupportedOperationException - - if EntityManager.isCreative() returns false.

alterPassword

public void alterPassword(User user,
                          java.lang.String plainTextPass)
                   throws EntityException
Encrypts the plain password, sets it on the user, and saves the user. Implementations supporting this will usually have an internal PasswordEncryptor.

Throws:
EntityException - - representing a system error.
java.lang.UnsupportedOperationException - - if EntityManager.isCreative() returns false.

saveUser

public void saveUser(User user)
              throws EntityException
Throws:
EntityException - - representing a system error.
java.lang.UnsupportedOperationException - - if EntityManager.isCreative() returns false.

removeUser

public void removeUser(User user)
                throws EntityException
Throws:
EntityException - - representing a system error.
java.lang.UnsupportedOperationException - - if isReadOnly(User) returns true.

isReadOnly

public boolean isReadOnly(User user)
                   throws EntityException
Returns:
true indicates that information on the user object cannot be altered in the storage system (see RepositoryIdentifier), false indicates that the storage system will save changes or that this UserManager does not know about the User.
Throws:
EntityException


Copyright © 2005-2007 Atlassian Software Systems Pty Ltd. All Rights Reserved.