@Deprecated
public class WaitingThread
extends java.lang.Object
| 构造器和说明 |
|---|
WaitingThread(java.util.concurrent.locks.Condition cond,
RouteSpecificPool pool)
已过时。
Creates a new entry for a waiting thread.
|
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
await(java.util.Date deadline)
已过时。
Blocks the calling thread.
|
java.util.concurrent.locks.Condition |
getCondition()
已过时。
Obtains the condition.
|
RouteSpecificPool |
getPool()
已过时。
Obtains the pool, if there is one.
|
java.lang.Thread |
getThread()
已过时。
Obtains the thread, if there is one.
|
void |
interrupt()
已过时。
|
void |
wakeup()
已过时。
Wakes up the waiting thread.
|
public WaitingThread(java.util.concurrent.locks.Condition cond,
RouteSpecificPool pool)
cond - the condition for which to waitpool - the pool on which the thread will be waiting,
or nullpublic final java.util.concurrent.locks.Condition getCondition()
nullpublic final RouteSpecificPool getPool()
nullpublic final java.lang.Thread getThread()
nullpublic boolean await(java.util.Date deadline)
throws java.lang.InterruptedException
deadline - when to time out, or null for no timeouttrue if the condition was satisfied,
false in case of a timeout.
Typically, a call to wakeup() is used to indicate
that the condition was satisfied. Since the condition is
accessible outside, this cannot be guaranteed though.java.lang.InterruptedException - if the waiting thread was interruptedwakeup()public void wakeup()
public void interrupt()