|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.directory.server.ldap.handlers.SearchTimeLimitingMonitor
public class SearchTimeLimitingMonitor
A ClosureMonitor implementation which takes into account a time limit.
| Constructor Summary | |
|---|---|
SearchTimeLimitingMonitor(long timeToLive,
java.util.concurrent.TimeUnit unit)
Creates a new instance of SearchTimeLimitingMonitor. |
|
| Method Summary | |
|---|---|
void |
checkNotClosed()
Checks if state of this ClosureMonitor is set to closed and if so, throws the causing Exception. |
void |
close()
Sets monitor state to closed, and sets the cause to a CursorClosedException without an error message string. |
void |
close(java.lang.Exception cause)
Sets monitor state to closed, and sets the cause to a specific Exception. |
void |
close(java.lang.String cause)
Sets monitor state to closed, and sets the cause to a CursorClosedException with a specific error message string. |
java.lang.Exception |
getCause()
Gets the cause of the closure. |
boolean |
isClosed()
Gets whether the state of this ClosureMonitor is set to closed. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SearchTimeLimitingMonitor(long timeToLive,
java.util.concurrent.TimeUnit unit)
timeToLive - the time before changing state to closed.unit - the time units for the timeToLive parameterTimeUnit}| Method Detail |
|---|
public void checkNotClosed()
throws java.lang.Exception
ClosureMonitor
checkNotClosed in interface ClosureMonitorjava.lang.Exception - the cause of the closurepublic void close()
ClosureMonitor
close in interface ClosureMonitorpublic void close(java.lang.String cause)
ClosureMonitor
close in interface ClosureMonitorcause - error message stringpublic void close(java.lang.Exception cause)
ClosureMonitor
close in interface ClosureMonitorcause - the exception to associate with the closurepublic java.lang.Exception getCause()
ClosureMonitor
getCause in interface ClosureMonitorpublic boolean isClosed()
ClosureMonitor
isClosed in interface ClosureMonitor
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||