|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--com.ibm.wbi.util.EventSemaphore
EventSemaphore implments a standard wait/post model semaphore.
| Field Summary | |
static long |
SEM_INDEFINITE_WAIT
Waits should wait forever. |
| Constructor Summary | |
EventSemaphore()
Create a semaphore. |
|
EventSemaphore(boolean posted)
Create a semaphore with an optional posted state. |
|
| Method Summary | |
int |
clear()
Clear the current semaphore. |
int |
post()
Posts the current semaphore. |
int |
queryPosts()
Query the number of posts. |
int |
waitFor()
Indefinite wait for a post to satisfy our wait. |
int |
waitFor(long waitMilliSeconds)
Bounded wait for a post to satisfy our wait. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final long SEM_INDEFINITE_WAIT
| Constructor Detail |
public EventSemaphore()
public EventSemaphore(boolean posted)
posted - If true, the initial post count is 1,
0 otherwise.| Method Detail |
public int post()
public int clear()
public int queryPosts()
public int waitFor()
public int waitFor(long waitMilliSeconds)
waitMilliSeconds - The number of uSeconds to wait before
returning.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||