Class BindResult

    • Constructor Detail

      • BindResult

        public BindResult​(int messageID,
                          @NotNull
                          ResultCode resultCode,
                          @Nullable
                          java.lang.String diagnosticMessage,
                          @Nullable
                          java.lang.String matchedDN,
                          @Nullable
                          java.lang.String[] referralURLs,
                          @Nullable
                          Control[] responseControls)
        Creates a new bind result with the provided information.
        Parameters:
        messageID - The message ID for the LDAP message that is associated with this bind result.
        resultCode - The result code from the response.
        diagnosticMessage - The diagnostic message from the response, if available.
        matchedDN - The matched DN from the response, if available.
        referralURLs - The set of referral URLs from the response, if available.
        responseControls - The set of controls from the response, if available.
      • BindResult

        public BindResult​(int messageID,
                          @NotNull
                          ResultCode resultCode,
                          @Nullable
                          java.lang.String diagnosticMessage,
                          @Nullable
                          java.lang.String matchedDN,
                          @Nullable
                          java.lang.String[] referralURLs,
                          @Nullable
                          Control[] responseControls,
                          @Nullable
                          ASN1OctetString serverSASLCredentials)
        Creates a new bind result with the provided information.
        Parameters:
        messageID - The message ID for the LDAP message that is associated with this bind result.
        resultCode - The result code from the response.
        diagnosticMessage - The diagnostic message from the response, if available.
        matchedDN - The matched DN from the response, if available.
        referralURLs - The set of referral URLs from the response, if available.
        responseControls - The set of controls from the response, if available.
        serverSASLCredentials - The server SASL credentials from the response, if available.
      • BindResult

        public BindResult​(@NotNull
                          LDAPResult ldapResult)
        Creates a new bind result from the provided generic LDAP result.
        Parameters:
        ldapResult - The LDAP result to use to create this bind result.
      • BindResult

        public BindResult​(@NotNull
                          LDAPException exception)
        Creates a new bind result from the provided LDAPException.
        Parameters:
        exception - The LDAPException to use to create this bind result.
      • BindResult

        protected BindResult​(@NotNull
                             BindResult bindResult)
        Creates a new bind result from the provided bind result. This constructor may be used in creating custom subclasses.
        Parameters:
        bindResult - The bind result to use to create this bind result.
    • Method Detail

      • getServerSASLCredentials

        @Nullable
        public ASN1OctetString getServerSASLCredentials()
        Retrieves the server SASL credentials from the bind result, if available.
        Returns:
        The server SASL credentials from the bind response, or null if none were provided.
      • toString

        public void toString​(@NotNull
                             java.lang.StringBuilder buffer)
        Appends a string representation of this LDAP result to the provided buffer.
        Specified by:
        toString in interface LDAPResponse
        Overrides:
        toString in class LDAPResult
        Parameters:
        buffer - The buffer to which to append a string representation of this LDAP result.