public class SearchFuture extends ResponseFuture<SearchResponse>
cancelled, connection, messageId, queue
Constructor and Description |
---|
SearchFuture(LdapConnection connection,
int messageId)
Creates a new instance of SearchFuture.
|
Modifier and Type | Method and Description |
---|---|
SearchResponse |
get()
Get the SearchResponse, blocking until one is received.
|
SearchResponse |
get(long timeout,
TimeUnit unit)
Get the SearchResponse, blocking until one is received, or until the
given timeout is reached.
|
String |
toString() |
cancel, isCancelled, isDone, set
public SearchFuture(LdapConnection connection, int messageId)
connection
- The LdapConnectionmessageId
- The associated messageIdpublic SearchResponse get() throws InterruptedException, ExecutionException
get
in interface Future<SearchResponse>
get
in class ResponseFuture<SearchResponse>
InterruptedException
- if the operation has been cancelled by clientExecutionException
public SearchResponse get(long timeout, TimeUnit unit) throws InterruptedException, ExecutionException, TimeoutException
get
in interface Future<SearchResponse>
get
in class ResponseFuture<SearchResponse>
timeout
- Number of TimeUnit to waitunit
- The TimeUnitInterruptedException
- if the operation has been cancelled by clientExecutionException
TimeoutException
public String toString()
toString
in class ResponseFuture<SearchResponse>
Copyright © 2009-2013 The Apache Software Foundation. All Rights Reserved.