|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectmoss.kernel.Semaphore
public class Semaphore
This class provides a low-level semaphore. Unlike MSemaphore(), this will "hold up" a virtual-processor if it waits.
| Constructor Summary | |
|---|---|
Semaphore()
creates and initialises a semaphore (default is to 1, for a mutex) |
|
Semaphore(int value)
creates and initialises a semaphore to the given value |
|
| Method Summary | |
|---|---|
void |
sem_signal()
signal this semaphore |
boolean |
sem_wait()
wait on this semaphore |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Semaphore()
public Semaphore(int value)
value - initial semaphore value| Method Detail |
|---|
public boolean sem_wait()
public void sem_signal()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||