public class Signal extends Object
Constructor and Description |
---|
Signal() |
Modifier and Type | Method and Description |
---|---|
void |
await()
Blocking call awaits the signal.
|
boolean |
await(long time,
TimeUnit unit)
Blocking call awaits the signal for the specified duration.
|
boolean |
isSignalled()
Non-blocking call immediately returns with the current status of the signal.
|
void |
signal()
Signals.
|
public boolean await(long time, TimeUnit unit) throws InterruptedException
time
- duration in time unitsunit
- time unitInterruptedException
signal()
public void await() throws InterruptedException
InterruptedException
- if interrupted while waitingsignal()
public void signal()
public boolean isSignalled()
Copyright © 2009–2018. All rights reserved.