|
Knopflerfish OSGi 5.0.0 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.knopflerfish.util.Semaphore
public class Semaphore
The Semaphore
class handles synchronization and waiting for
values.
Constructor Summary | |
---|---|
Semaphore()
|
Method Summary | |
---|---|
void |
close()
|
java.lang.Object |
get(long timeout)
Waits up to timeout milliseconds for this Semaphore to
receive a value. |
void |
reset()
|
void |
set(java.lang.Object v)
Sets the value of this Semaphore. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Semaphore()
Method Detail |
---|
public java.lang.Object get(long timeout)
timeout
milliseconds for this Semaphore to
receive a value.
public void set(java.lang.Object v)
get(long)
to return the value. If set(Object)
is called several times with a short or no delay
between the calls, the exact value returned by a given blocked
call to get(long)
is not deterministic.
v
- The new value.public void reset()
public void close()
|
Knopflerfish OSGi 5.0.0 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |