Package org.ldaptive.transport.netty
Class NettyConnection.BindOperationHandle
java.lang.Object
org.ldaptive.transport.DefaultOperationHandle<BindRequest,BindResponse>
org.ldaptive.transport.netty.NettyConnection.BindOperationHandle
- All Implemented Interfaces:
OperationHandle<BindRequest,
BindResponse>
- Enclosing class:
- NettyConnection
public class NettyConnection.BindOperationHandle
extends DefaultOperationHandle<BindRequest,BindResponse>
Bind specific operation handle that locks other operations until the bind completes.
-
Field Summary
Fields inherited from class org.ldaptive.transport.DefaultOperationHandle
logger
-
Constructor Summary
ConstructorsConstructorDescriptionBindOperationHandle
(BindRequest req, TransportConnection conn, Duration timeout) Creates a new bind operation handle. -
Method Summary
Modifier and TypeMethodDescriptionawait()
Waits for a result or reports a timeout exception.execute()
Convenience method that invokesOperationHandle.send()
followed byOperationHandle.await()
.send()
Sends this request to the server.Methods inherited from class org.ldaptive.transport.DefaultOperationHandle
abandon, abandon, cancel, consumedMessage, control, exception, getMessageID, getOnComplete, getOnControl, getOnException, getOnIntermediate, getOnReferral, getOnResult, getOnUnsolicitedNotification, getReceivedTime, getRequest, getSentTime, getThrowCondition, hasConsumedMessage, initializeMessageFunctional, intermediate, messageID, onComplete, onControl, onException, onIntermediate, onReferral, onResult, onUnsolicitedNotification, referral, result, sent, throwIf, toString, unsolicitedNotification
-
Constructor Details
-
BindOperationHandle
BindOperationHandle(BindRequest req, TransportConnection conn, Duration timeout) Creates a new bind operation handle.- Parameters:
req
- bind request to expect a response forconn
- the request will be executed ontimeout
- duration to wait for a response
-
-
Method Details
-
send
Description copied from interface:OperationHandle
Sends this request to the server.- Specified by:
send
in interfaceOperationHandle<BindRequest,
BindResponse> - Overrides:
send
in classDefaultOperationHandle<BindRequest,
BindResponse> - Returns:
- this handle
-
await
Description copied from interface:OperationHandle
Waits for a result or reports a timeout exception.- Specified by:
await
in interfaceOperationHandle<BindRequest,
BindResponse> - Overrides:
await
in classDefaultOperationHandle<BindRequest,
BindResponse> - Returns:
- result of the operation or empty if the operation is abandoned
-
execute
Description copied from interface:OperationHandle
Convenience method that invokesOperationHandle.send()
followed byOperationHandle.await()
. Provides a single method to make a synchronous request.- Returns:
- result of the operation or empty if the operation is abandoned
- Throws:
LdapException
- if an error occurs executing the request
-