org.pentaho.platform.plugin.services.security.userrole.ldap
Class DefaultLdapUserRoleListService

java.lang.Object
  extended by org.pentaho.platform.plugin.services.security.userrole.ldap.DefaultLdapUserRoleListService
All Implemented Interfaces:
IUserRoleListService, org.springframework.beans.factory.InitializingBean

public class DefaultLdapUserRoleListService
extends Object
implements IUserRoleListService, org.springframework.beans.factory.InitializingBean


Constructor Summary
DefaultLdapUserRoleListService()
           
DefaultLdapUserRoleListService(Comparator<String> usernameComparator, Comparator<org.springframework.security.GrantedAuthority> grantedAuthorityComparator)
           
 
Method Summary
 void afterPropertiesSet()
           
 org.springframework.security.GrantedAuthority[] getAllAuthorities()
          Returns all authorities known to the provider.
 String[] getAllUsernames()
          Returns all user names known to the provider.
 org.springframework.security.GrantedAuthority[] getAuthoritiesForUser(String username)
          Returns all authorities granted for a specified user.
 String[] getUsernamesInRole(org.springframework.security.GrantedAuthority authority)
          Returns all known users in the specified role.
 void setAllAuthoritiesSearch(LdapSearch allAuthoritiesSearch)
           
 void setAllUsernamesSearch(LdapSearch allUsernamesSearch)
           
 void setGrantedAuthorityComparator(Comparator<org.springframework.security.GrantedAuthority> grantedAuthorityComparator)
           
 void setUserDetailsService(org.springframework.security.userdetails.ldap.LdapUserDetailsService userDetailsService)
           
 void setUsernameComparator(Comparator<String> usernameComparator)
           
 void setUsernamesInRoleSearch(LdapSearch usernamesInRoleSearch)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultLdapUserRoleListService

public DefaultLdapUserRoleListService()

DefaultLdapUserRoleListService

public DefaultLdapUserRoleListService(Comparator<String> usernameComparator,
                                      Comparator<org.springframework.security.GrantedAuthority> grantedAuthorityComparator)
Method Detail

afterPropertiesSet

public void afterPropertiesSet()
                        throws Exception
Specified by:
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
Throws:
Exception

getAllAuthorities

public org.springframework.security.GrantedAuthority[] getAllAuthorities()
Description copied from interface: IUserRoleListService
Returns all authorities known to the provider. Cannot return null

Specified by:
getAllAuthorities in interface IUserRoleListService
Returns:
the authorities (never null)

getAllUsernames

public String[] getAllUsernames()
Description copied from interface: IUserRoleListService
Returns all user names known to the provider. Cannot return null

Specified by:
getAllUsernames in interface IUserRoleListService
Returns:
the users (never null)

getUsernamesInRole

public String[] getUsernamesInRole(org.springframework.security.GrantedAuthority authority)
Description copied from interface: IUserRoleListService
Returns all known users in the specified role. Cannot return null

Specified by:
getUsernamesInRole in interface IUserRoleListService
Parameters:
authority - The authority to look users up by. Cannot be null
Returns:
the users. (never null)

getAuthoritiesForUser

public org.springframework.security.GrantedAuthority[] getAuthoritiesForUser(String username)
Description copied from interface: IUserRoleListService
Returns all authorities granted for a specified user.

Specified by:
getAuthoritiesForUser in interface IUserRoleListService
Parameters:
username - The name of the user to look up authorities for
Returns:
the authorities. (Never null)

setAllUsernamesSearch

public void setAllUsernamesSearch(LdapSearch allUsernamesSearch)

setAllAuthoritiesSearch

public void setAllAuthoritiesSearch(LdapSearch allAuthoritiesSearch)

setUsernamesInRoleSearch

public void setUsernamesInRoleSearch(LdapSearch usernamesInRoleSearch)

setUserDetailsService

public void setUserDetailsService(org.springframework.security.userdetails.ldap.LdapUserDetailsService userDetailsService)

setGrantedAuthorityComparator

public void setGrantedAuthorityComparator(Comparator<org.springframework.security.GrantedAuthority> grantedAuthorityComparator)

setUsernameComparator

public void setUsernameComparator(Comparator<String> usernameComparator)