Class AbstractLdapFactory<T extends BaseLdap>

  • Type Parameters:
    T - type of ldap object
    All Implemented Interfaces:
    LdapFactory<T>
    Direct Known Subclasses:
    DefaultLdapFactory

    public abstract class AbstractLdapFactory<T extends BaseLdap>
    extends java.lang.Object
    implements LdapFactory<T>
    AbstractLdapFactory provides a basic implementation of an ldap factory.
    Version:
    $Revision: 1330 $ $Date: 2010-05-24 00:10:53 +0200 (Mon, 24 May 2010) $
    Author:
    Middleware Services
    • Field Detail

      • logger

        protected final org.apache.commons.logging.Log logger
        Log for this class.
    • Constructor Detail

      • AbstractLdapFactory

        public AbstractLdapFactory()
    • Method Detail

      • setLdapActivator

        public void setLdapActivator​(LdapActivator<T> la)
        Sets the ldap activator for this factory.
        Parameters:
        la - ldap activator
      • getLdapActivator

        public LdapActivator<T> getLdapActivator()
        Returns the ldap activator for this factory.
        Returns:
        ldap activator
      • setLdapPassivator

        public void setLdapPassivator​(LdapPassivator<T> lp)
        Sets the ldap passivator for this factory.
        Parameters:
        lp - ldap passivator
      • getLdapPassivator

        public LdapPassivator<T> getLdapPassivator()
        Returns the ldap passivator for this factory.
        Returns:
        ldap passivator
      • setLdapValidator

        public void setLdapValidator​(LdapValidator<T> lv)
        Sets the ldap validator for this factory.
        Parameters:
        lv - ldap validator
      • getLdapValidator

        public LdapValidator<T> getLdapValidator()
        Returns the ldap validator for this factory.
        Returns:
        ldap validator
      • create

        public abstract T create()
        Create a new ldap object.
        Specified by:
        create in interface LdapFactory<T extends BaseLdap>
        Returns:
        ldap object
      • destroy

        public abstract void destroy​(T t)
        Destroy an ldap object.
        Specified by:
        destroy in interface LdapFactory<T extends BaseLdap>
        Parameters:
        t - ldap object
      • activate

        public boolean activate​(T t)
        Prepare the supplied object for placement in the pool.
        Specified by:
        activate in interface LdapFactory<T extends BaseLdap>
        Parameters:
        t - ldap object
        Returns:
        whether the supplied object successfully activated
      • passivate

        public boolean passivate​(T t)
        Prepare the supplied object for removal from the pool.
        Specified by:
        passivate in interface LdapFactory<T extends BaseLdap>
        Parameters:
        t - ldap object
        Returns:
        whether the supplied object successfully passivated
      • validate

        public boolean validate​(T t)
        Verify an ldap object is still viable for use in the pool.
        Specified by:
        validate in interface LdapFactory<T extends BaseLdap>
        Parameters:
        t - ldap object
        Returns:
        whether the supplied object is ready for use