Package org.ldaptive

Class LdapException

    • Field Detail

      • serialVersionUID

        private static final long serialVersionUID
        serialVersionUID.
        See Also:
        Constant Field Values
      • resultCode

        private final ResultCode resultCode
        ldap result code.
      • matchedDn

        private final String matchedDn
        response matched DN.
      • responseControls

        private final ResponseControl[] responseControls
        response controls.
      • referralURLs

        private final String[] referralURLs
        referral URLs.
      • messageId

        private final int messageId
        Message ID.
    • Constructor Detail

      • LdapException

        public LdapException​(String msg)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
      • LdapException

        public LdapException​(String msg,
                             ResultCode code)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
        code - result code
      • LdapException

        public LdapException​(String msg,
                             ResultCode code,
                             String dn)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
        code - result code
        dn - matched dn
      • LdapException

        public LdapException​(String msg,
                             ResultCode code,
                             String dn,
                             ResponseControl[] c)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
        code - result code
        dn - matched dn
        c - response controls
      • LdapException

        public LdapException​(String msg,
                             ResultCode code,
                             String dn,
                             ResponseControl[] c,
                             String[] urls)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
        code - result code
        dn - matched dn
        c - response controls
        urls - referral urls
      • LdapException

        public LdapException​(String msg,
                             ResultCode code,
                             String dn,
                             ResponseControl[] c,
                             String[] urls,
                             int id)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
        code - result code
        dn - matched dn
        c - response controls
        urls - referral urls
        id - message id
      • LdapException

        public LdapException​(Exception e)
        Creates a new ldap exception.
        Parameters:
        e - provider specific exception
      • LdapException

        public LdapException​(Exception e,
                             ResultCode code)
        Creates a new ldap exception.
        Parameters:
        e - provider specific exception
        code - result code
      • LdapException

        public LdapException​(Exception e,
                             ResultCode code,
                             String dn)
        Creates a new ldap exception.
        Parameters:
        e - provider specific exception
        code - result code
        dn - matched dn
      • LdapException

        public LdapException​(Exception e,
                             ResultCode code,
                             String dn,
                             ResponseControl[] c)
        Creates a new ldap exception.
        Parameters:
        e - provider specific exception
        code - result code
        dn - matched dn
        c - response controls
      • LdapException

        public LdapException​(Exception e,
                             ResultCode code,
                             String dn,
                             ResponseControl[] c,
                             String[] urls)
        Creates a new ldap exception.
        Parameters:
        e - provider specific exception
        code - result code
        dn - matched dn
        c - response controls
        urls - referral urls
      • LdapException

        public LdapException​(Exception e,
                             ResultCode code,
                             String dn,
                             ResponseControl[] c,
                             String[] urls,
                             int id)
        Creates a new ldap exception.
        Parameters:
        e - provider specific exception
        code - result code
        dn - matched dn
        c - response controls
        urls - referral urls
        id - message id
      • LdapException

        public LdapException​(String msg,
                             Exception e)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
        e - provider specific exception
      • LdapException

        public LdapException​(String msg,
                             Exception e,
                             ResultCode code)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
        e - provider specific exception
        code - result code
      • LdapException

        public LdapException​(String msg,
                             Exception e,
                             ResultCode code,
                             String dn)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
        e - provider specific exception
        code - result code
        dn - matched dn
      • LdapException

        public LdapException​(String msg,
                             Exception e,
                             ResultCode code,
                             String dn,
                             ResponseControl[] c)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
        e - provider specific exception
        code - result code
        dn - matched dn
        c - response controls
      • LdapException

        public LdapException​(String msg,
                             Exception e,
                             ResultCode code,
                             String dn,
                             ResponseControl[] c,
                             String[] urls)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
        e - provider specific exception
        code - result code
        dn - matched dn
        c - response controls
        urls - referral urls
      • LdapException

        public LdapException​(String msg,
                             Exception e,
                             ResultCode code,
                             String dn,
                             ResponseControl[] c,
                             String[] urls,
                             int id)
        Creates a new ldap exception.
        Parameters:
        msg - describing this exception
        e - provider specific exception
        code - result code
        dn - matched dn
        c - response controls
        urls - referral urls
        id - message id
    • Method Detail

      • getResultCode

        public ResultCode getResultCode()
        Returns the ldap result code associated with this exception. May be null if the provider did not set this value or could not determine this value.
        Returns:
        ldap result code
      • getMatchedDn

        public String getMatchedDn()
        Returns the matched DN produced by the ldap operation.
        Returns:
        matched DN
      • getControl

        public ResponseControl getControl​(String oid)
        Description copied from interface: ResponseMessage
        Returns the first response control with the supplied OID for this response message.
        Specified by:
        getControl in interface ResponseMessage
        Parameters:
        oid - of the response control to return
        Returns:
        response control or null if control could not be found
      • getReferralURLs

        public String[] getReferralURLs()
        Returns the referral URLs produced by the ldap operation.
        Returns:
        referral urls
      • getMessageId

        public int getMessageId()
        Description copied from interface: ResponseMessage
        Returns the message ID for this response message.
        Specified by:
        getMessageId in interface ResponseMessage
        Returns:
        message id