Package org.forgerock.opendj.io
Class LdapReader
java.lang.Object
org.forgerock.opendj.io.LdapReader
Reads LDAP messages from an underlying ASN.1 reader.
Methods for creating LdapReaders are provided in the Ldap class.
-
Method Summary
Modifier and TypeMethodDescriptionbooleanReturnstrueif the next LDAP message can be read without blocking.Reads the next LDAP message from the underlying ASN.1 reader.Reads the next LDAP request message from the underlying ASN.1 reader.Reads the next LDAP response message from the underlying ASN.1 reader.Reads the next LDAP response message from the underlying ASN.1 reader performing minimal decoding.
-
Method Details
-
hasMessageAvailable
Returnstrueif the next LDAP message can be read without blocking.- Returns:
trueif the next LDAP message can be read without blocking orfalseotherwise.- Throws:
DecodeException- If the available data was not a valid LDAP message.IOException- If an unexpected IO error occurred.
-
readLdapMessage
Reads the next LDAP message from the underlying ASN.1 reader.- Returns:
- A fully decoded
LdapMessage. - Throws:
DecodeException- If the available data was not a valid LDAP message.IOException- If an unexpected IO error occurred.
-
readLdapRequestMessage
Reads the next LDAP request message from the underlying ASN.1 reader.- Returns:
- A fully decoded
LdapMessagewrapping aRequest. - Throws:
DecodeException- If the available data was not a valid LDAP message.IOException- If an unexpected IO error occurred.
-
readLdapResponseMessage
Reads the next LDAP response message from the underlying ASN.1 reader.- Returns:
- A fully decoded
LdapMessagewrapping aResponse. - Throws:
DecodeException- If the available data was not a valid LDAP message.IOException- If an unexpected IO error occurred.
-
readMinimalResponseMessage
Reads the next LDAP response message from the underlying ASN.1 reader performing minimal decoding. This method is intended for use within performance tools in order to minimize unnecessary processing.- Returns:
- A fully decoded
LdapMessagewrapping aResponse. - Throws:
DecodeException- If the available data was not a valid LDAP message.IOException- If an unexpected IO error occurred.
-