|
More information: http://www.cs.berkeley.edu/~mdw/proj/java-nbio/ | |||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Object
|
+--seda.nbio.SelectSetImpl
|
+--seda.nbio.SelectSetDevPollImpl
SelectSetDevPollImpl is an implementation of SelectSet which uses the UNIX /dev/poll mechanism.
SelectSet| Constructor Summary | |
(package private) |
SelectSetDevPollImpl()
Create a SelectSetDevPollImpl with no SelectItems. |
| Method Summary | |
(package private) void |
add(SelectItem sel)
Add a SelectItem to this SelectSetDevPollImpl. |
(package private) void |
add(SelectItem[] selarr)
Add all of the SelectItems in the given array to the SelectSetDevPollImpl. |
(package private) SelectItem |
elementAt(int index)
Return the SelectItem at the given index. |
(package private) SelectItem[] |
getEvents()
Returns an array of SelectItems for which some events have occurred (that is, that the revents field is nonzero). |
(package private) SelectItem[] |
getEvents(short mask)
Returns an array of SelectItems for which events matching the given event mask have occurred (that is, that the revents field matches the given mask). |
(package private) static boolean |
isSupported()
Returns true if /dev/poll is supported on this platform. |
(package private) int |
numActive()
Return the number of active SelectItems in this SelectSetDevPollImpl. |
(package private) void |
remove(int index)
Remove the SelectItem at the given index from the SelectSetDevPollImpl. |
(package private) void |
remove(SelectItem sel)
Remove a SelectItem from the SelectSetDevPollImpl. |
(package private) void |
remove(SelectItem[] selarr)
Remove all of the SelectItems in the given array from the SelectSetDevPollImpl. |
(package private) int |
select(int timeout)
Wait for events to occur on the SelectItems in this SelectSetDevPollImpl. |
(package private) int |
size()
Return the number of SelectItems in this SelectSetDevPollImpl. |
java.lang.String |
toString()
|
(package private) void |
update()
Push updated event masks for all SelectItems in this SelectSet to the /dev/poll device. |
(package private) void |
update(SelectItem sel)
Push updated event masks for all SelectItems in this SelectSet to native code. |
| Methods inherited from class java.lang.Object |
|
| Constructor Detail |
SelectSetDevPollImpl()
| Method Detail |
static boolean isSupported()
void add(SelectItem sel)
add in class SelectSetImplvoid add(SelectItem[] selarr)
add in class SelectSetImplvoid remove(SelectItem sel)
remove in class SelectSetImplvoid remove(SelectItem[] selarr)
remove in class SelectSetImplvoid remove(int index)
remove in class SelectSetImplvoid update()
update in class SelectSetImplvoid update(SelectItem sel)
update in class SelectSetImplint size()
size in class SelectSetImplint numActive()
numActive in class SelectSetImplSelectItem elementAt(int index)
elementAt in class SelectSetImplint select(int timeout)
IMPORTANT NOTE: If timeout is non-zero, this call will block the thread which invokes it. If you are using Green Threads, this will block the entire JVM. Unless you have a single-threaded application, you should only use SelectSet.select() with native threads.
select in class SelectSetImpltimeout - The maximum number of milliseconds to block waiting
for an event to occur. A timeout of 0 means than select should not block;
a timeout of -1 means that select should block indefinitely.SelectItem[] getEvents(short mask)
getEvents in class SelectSetImplSelectItem[] getEvents()
getEvents in class SelectSetImplpublic java.lang.String toString()
toString in class java.lang.Object
|
More information: http://www.cs.berkeley.edu/~mdw/proj/java-nbio/ | |||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||