Package org.forgerock.opendj.ldap
Interface LdapResultHandler<S>
- Type Parameters:
S
- The type of result handled by this result handler.
- All Superinterfaces:
ExceptionHandler<LdapException>
,ResultHandler<S>
A completion handler for consuming the result of an asynchronous operation or
connection attempts.
A result completion handler may be specified when performing asynchronous
operations using a Connection
object or when connecting
asynchronously to a remote Directory Server using an
ConnectionFactory
. The handleResult(S)
method is invoked when
the operation or connection attempt completes successfully. The
handleException(LdapException)
method is invoked if the operation or connection
attempt fails.
Implementations of these methods should complete in a timely manner so as to avoid keeping the invoking thread from dispatching to other completion handlers.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
handleException
(LdapException exception) Invoked when the asynchronous operation has failed.void
handleResult
(S result) Invoked when the asynchronous operation has completed successfully.
-
Method Details
-
handleException
Invoked when the asynchronous operation has failed.- Specified by:
handleException
in interfaceExceptionHandler<S>
- Parameters:
exception
- The error result exception indicating why the asynchronous operation has failed.
-
handleResult
Invoked when the asynchronous operation has completed successfully.- Specified by:
handleResult
in interfaceResultHandler<S>
- Parameters:
result
- The result of the asynchronous operation.
-