|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.appfuse.service.impl.GenericManagerImpl<org.appfuse.model.User,Long>
org.appfuse.service.impl.UserManagerImpl
@Service(value="userManager") public class UserManagerImpl
Implementation of UserManager interface.
| Field Summary |
|---|
| Fields inherited from class org.appfuse.service.impl.GenericManagerImpl |
|---|
dao, log |
| Constructor Summary | |
|---|---|
UserManagerImpl()
|
|
| Method Summary | |
|---|---|
org.appfuse.model.User |
getUser(String userId)
Retrieves a user by userId. |
org.appfuse.model.User |
getUserByUsername(String username)
Finds a user by their username. |
List<org.appfuse.model.User> |
getUsers()
Retrieves a list of all users. |
void |
removeUser(String userId)
Removes a user from the database by their userId |
void |
removeUser(org.appfuse.model.User user)
Removes a user from the database |
org.appfuse.model.User |
saveUser(org.appfuse.model.User user)
Saves a user's information. |
List<org.appfuse.model.User> |
search(String searchTerm)
Search a user for search terms. |
void |
setPasswordEncoder(org.springframework.security.authentication.encoding.PasswordEncoder passwordEncoder)
|
void |
setUserDao(UserDao userDao)
Convenience method for testing - allows you to mock the DAO and set it on an interface. |
| Methods inherited from class org.appfuse.service.impl.GenericManagerImpl |
|---|
exists, get, getAll, reindex, reindexAll, remove, remove, save, search |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.appfuse.service.GenericManager |
|---|
exists, get, getAll, reindex, reindexAll, remove, remove, save, search |
| Constructor Detail |
|---|
public UserManagerImpl()
| Method Detail |
|---|
@Autowired public void setPasswordEncoder(org.springframework.security.authentication.encoding.PasswordEncoder passwordEncoder)
@Autowired public void setUserDao(UserDao userDao)
UserManager
setUserDao in interface UserManageruserDao - the UserDao implementation to usepublic org.appfuse.model.User getUser(String userId)
getUser in interface UserManagergetUser in interface UserServiceuserId - the identifier for the user
public List<org.appfuse.model.User> getUsers()
getUsers in interface UserManagergetUsers in interface UserService
public org.appfuse.model.User saveUser(org.appfuse.model.User user)
throws UserExistsException
saveUser in interface UserManagersaveUser in interface UserServiceuser - the user's information
UserExistsException - thrown when user already existspublic void removeUser(org.appfuse.model.User user)
removeUser in interface UserManageruser - the user to removepublic void removeUser(String userId)
removeUser in interface UserManagerremoveUser in interface UserServiceuserId - the user's id
public org.appfuse.model.User getUserByUsername(String username)
throws org.springframework.security.core.userdetails.UsernameNotFoundException
getUserByUsername in interface UserManagergetUserByUsername in interface UserServiceusername - the login name of the human
org.springframework.security.core.userdetails.UsernameNotFoundException - thrown when username not foundpublic List<org.appfuse.model.User> search(String searchTerm)
search in interface UserManagersearchTerm - the search terms.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||