Class SearchRequestProtocolOp


  • public class SearchRequestProtocolOp
    extends ProtocolOp
    This class defines the structures and methods for an LDAP search request protocol op, which is used to locate entries based on a set of criteria.
    • Constructor Detail

      • SearchRequestProtocolOp

        public SearchRequestProtocolOp​(ByteString baseDN,
                                       SearchScope scope,
                                       DereferenceAliasesPolicy dereferencePolicy,
                                       int sizeLimit,
                                       int timeLimit,
                                       boolean typesOnly,
                                       RawFilter filter,
                                       Set<String> attributes)
        Creates a new search request protocol op with the provided information.
        Parameters:
        baseDN - The base DN for this search request.
        scope - The scope for this search request.
        dereferencePolicy - The alias dereferencing policy for this search request.
        sizeLimit - The size limit for this search request.
        timeLimit - The time limit for this search request.
        typesOnly - The typesOnly flag for this search request.
        filter - The filter for this search request.
        attributes - The set of requested attributes for this search request.
    • Method Detail

      • getBaseDN

        public ByteString getBaseDN()
        Retrieves the base DN for this search request.
        Returns:
        The base DN for this search request.
      • getScope

        public SearchScope getScope()
        Retrieves the scope for this search request.
        Returns:
        The scope for this search request.
      • getDereferencePolicy

        public DereferenceAliasesPolicy getDereferencePolicy()
        Retrieves the alias dereferencing policy for this search request.
        Returns:
        The alias dereferencing policy for this search request.
      • getSizeLimit

        public int getSizeLimit()
        Retrieves the size limit for this search request.
        Returns:
        The size limit for this search request.
      • getTimeLimit

        public int getTimeLimit()
        Retrieves the time limit for this search request.
        Returns:
        The time limit for this search request.
      • getTypesOnly

        public boolean getTypesOnly()
        Retrieves the value of the typesOnly flag for this search request.
        Returns:
        The value of tye typesOnly flag for this search request.
      • getFilter

        public RawFilter getFilter()
        Retrieves the filter for this search request.
        Returns:
        The filter for this search request.
      • getAttributes

        public Set<String> getAttributes()
        Retrieves the set of requested attributes for this search request. The returned list may be modified by the caller.
        Returns:
        The set of requested attributes for this search request.
      • getType

        public byte getType()
        Description copied from class: ProtocolOp
        Retrieves the BER type for this protocol op.
        Specified by:
        getType in class ProtocolOp
        Returns:
        The BER type for this protocol op.
      • getProtocolOpName

        public String getProtocolOpName()
        Description copied from class: ProtocolOp
        Retrieves the name for this protocol op type.
        Specified by:
        getProtocolOpName in class ProtocolOp
        Returns:
        The name for this protocol op type.
      • write

        public void write​(ASN1Writer stream)
                   throws IOException
        Description copied from class: ProtocolOp
        Writes this protocol op to an ASN.1 output stream.
        Specified by:
        write in class ProtocolOp
        Parameters:
        stream - The ASN.1 output stream to write to.
        Throws:
        IOException - If a problem occurs while writing to the stream.
      • toString

        public void toString​(StringBuilder buffer)
        Description copied from class: ProtocolOp
        Appends a string representation of this LDAP protocol op to the provided buffer.
        Specified by:
        toString in class ProtocolOp
        Parameters:
        buffer - The buffer to which the string should be appended.
      • toString

        public void toString​(StringBuilder buffer,
                             int indent)
        Description copied from class: ProtocolOp
        Appends a multi-line string representation of this LDAP protocol op to the provided buffer.
        Specified by:
        toString in class ProtocolOp
        Parameters:
        buffer - The buffer to which the information should be appended.
        indent - The number of spaces from the margin that the lines should be indented.