Class LDAPUser


  • public class LDAPUser
    extends Object
    This class reads user infos from the LDAP DB and translate it into the UserDetail format
    Author:
    tleroi
    • Constructor Detail

      • LDAPUser

        public LDAPUser()
    • Method Detail

      • init

        public void init​(LDAPSettings driverSettings,
                         DomainDriver driverParent,
                         LDAPSynchroCache synchroCache)
        Initialize the settings from the read ones
        Parameters:
        driverSettings - the settings retrieved from the property file
      • getAllUsers

        public UserDetail[] getAllUsers​(String lds,
                                        String extraFilter)
                                 throws AdminException
        Return all users found in the baseDN tree
        Parameters:
        lds - the LDAP connection
        Returns:
        all founded users
        Throws:
        AdminException - if an error occur during LDAP operations
      • listUserFulls

        public List<UserFull> listUserFulls​(String lds,
                                            Collection<String> ids,
                                            int domainId)
                                     throws AdminException
        Return a list of UserFull instance each one filled with the infos of the user having ID = id

        NOTE : the DomainID and the ID are not set.

        Parameters:
        lds - the LDAP connection
        ids - list of user id
        Returns:
        the list of UserFull instance.
        Throws:
        AdminException - if an error occur during LDAP operations or if the user is not found
      • listUsers

        public List<UserDetail> listUsers​(String lds,
                                          Collection<String> ids)
                                   throws AdminException
        Return a list of UserDetail instance each one filled with the infos of the user having ID = id

        NOTE : the DomainID and the ID are not set.

        Parameters:
        lds - the LDAP connection
        ids - list of user id
        Returns:
        the list of UserDetail instance.
        Throws:
        AdminException - if an error occur during LDAP operations or if the user is not found
      • getUserAttributes

        public String[] getUserAttributes()