org.acegisecurity.userdetails.memory
Class InMemoryDaoImpl
java.lang.Object
org.acegisecurity.userdetails.memory.InMemoryDaoImpl
- All Implemented Interfaces:
- UserDetailsService, InitializingBean
public class InMemoryDaoImpl
- extends Object
- implements UserDetailsService, InitializingBean
Retrieves user details from an in-memory list created by the bean context.
- Version:
- $Id: InMemoryDaoImpl.java,v 1.9 2005/11/29 13:10:09 benalex Exp $
- Author:
- Ben Alex
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
InMemoryDaoImpl
public InMemoryDaoImpl()
setUserMap
public void setUserMap(UserMap userMap)
getUserMap
public UserMap getUserMap()
setUserProperties
public void setUserProperties(Properties props)
- Modifies the internal
UserMap to reflect the
Properties instance passed. This helps externalise user
information to another file etc.
- Parameters:
props - the account information in a Properties object
format
afterPropertiesSet
public void afterPropertiesSet()
throws Exception
- Specified by:
afterPropertiesSet in interface InitializingBean
- Throws:
Exception
loadUserByUsername
public UserDetails loadUserByUsername(String username)
throws UsernameNotFoundException,
DataAccessException
- Description copied from interface:
UserDetailsService
- Locates the user based on the username. In the actual implementation,
the search may possibly be case insensitive, or case insensitive
depending on how the implementaion instance is configured. In this
case, the
UserDetails object that comes back may have a
username that is of a different case than what was actually requested..
- Specified by:
loadUserByUsername in interface UserDetailsService
- Parameters:
username - the username presented to the DaoAuthenticationProvider
- Returns:
- a fully populated user record (never
null)
- Throws:
UsernameNotFoundException - if the user could not be found or the
user has no GrantedAuthority
DataAccessException - if user could not be found for a
repository-specific reason
Copyright © 2004-2005 Acegi Technology Pty Limited. All Rights Reserved.