|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IDispatcher<T extends IHandle>
A Dispatcher encapsulates an underlying Selector. It is responsible
for the channel handle management. If a readiness event occurs, the
assigned IEventHandler
will be called.
Method Summary | |
---|---|
void |
deregister(T handle)
deregister a handle. |
IEventHandler<T> |
getEventHandler()
get the event handler of this dispatcher . |
long |
getNumberOfHandledReads()
get the number of handled reads |
long |
getNumberOfHandledRegistrations()
get the number of handled registractions |
long |
getNumberOfHandledWrites()
get the number of handled writes |
java.util.Set<T> |
getRegistered()
return the registered handles |
void |
register(T handle,
int ops)
register a new handle. |
void |
updateInterestSet(T handle,
int ops)
announce a write for he given handle. |
Methods inherited from interface java.lang.Runnable |
---|
run |
Methods inherited from interface java.io.Closeable |
---|
close |
Method Detail |
---|
IEventHandler<T> getEventHandler()
void register(T handle, int ops) throws java.io.IOException
handle
- the handle to registerops
- the interest set
java.io.IOException
- If some I/O error occursvoid deregister(T handle) throws java.io.IOException
handle
- the handle to deregister
java.io.IOException
- If some I/O error occursjava.util.Set<T> getRegistered()
void updateInterestSet(T handle, int ops) throws java.io.IOException
handle
- the handle for the write needops
- the interest set
java.io.IOException
- if the given hnadle is invalidlong getNumberOfHandledRegistrations()
long getNumberOfHandledReads()
long getNumberOfHandledWrites()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |