public class DefaultSearchResultHandler extends java.lang.Object implements SearchResultHandler
This class is provided for convenience only. Override the appropriate handle...() method to intercept the appropriate result.
Constructor and Description |
---|
DefaultSearchResultHandler(SearchResultHandler resultHandler)
Construct a new instance of this class.
|
Modifier and Type | Method and Description |
---|---|
boolean |
handleEntry(SearchResultEntry entry)
Invoked each time a search result entry is returned from an asynchronous
search operation.
|
void |
handleErrorResult(Result error)
Invoked when the operation has failed.
|
boolean |
handleReference(DN dn,
SearchResultReference reference)
Invoked each time a search result reference is returned from an
asynchronous search operation.
|
void |
handleResult(Result result)
Invoked when the operation has completed successfully.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
handleErrorResult, handleResult
public DefaultSearchResultHandler(SearchResultHandler resultHandler)
resultHandler
- the handler that will receive all calls defined by
the SearchResultHandler interface.public boolean handleEntry(SearchResultEntry entry)
SearchResultHandler
handleEntry
in interface SearchResultHandler
entry
- The search result entry.true
if this handler should continue to be notified of any
remaining entries and references, or false
if the remaining
entries and references should be skipped for some reason (e.g. a
client side size limit has been reached).public boolean handleReference(DN dn, SearchResultReference reference)
SearchResultHandler
handleReference
in interface SearchResultHandler
dn
- The DN related to the provided search reference.reference
- The search result reference.true
if this handler should continue to be notified of any
remaining entries and references, or false
if the remaining
entries and references should be skipped for some reason (e.g. a
client side size limit has been reached).public void handleErrorResult(Result error)
ResultHandler
handleErrorResult
in interface ResultHandler
error
- The error result exception indicating why the operation has failed.public void handleResult(Result result)
ResultHandler
handleResult
in interface ResultHandler
result
- The result of the operation.