public final class ClientChannelWatcher
extends java.lang.Thread
Modifier and Type | Field and Description |
---|---|
private static java.util.Set<IOFHandler> |
controllers |
private java.lang.Object |
guard |
private boolean |
quit |
private java.nio.channels.Selector |
read_selector |
Constructor and Description |
---|
ClientChannelWatcher() |
Modifier and Type | Method and Description |
---|---|
(package private) void |
addClient(java.nio.channels.SocketChannel client) |
static void |
deregisterController(IOFHandler controller) |
static java.util.Set<IOFHandler> |
getHandlersFor(Connection conn) |
private boolean |
handleConnectedEvent(Connection conn) |
private void |
handleDisconnectedEvent(Connection conn) |
private boolean |
handleReadEvent(Connection conn) |
static void |
registerController(IOFHandler controller) |
void |
run() |
(package private) void |
shutdown() |
(package private) void |
wakeup() |
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
private volatile boolean quit
private java.lang.Object guard
private java.nio.channels.Selector read_selector
private static java.util.Set<IOFHandler> controllers
ClientChannelWatcher() throws java.io.IOException
java.io.IOException
public static void registerController(IOFHandler controller)
public static void deregisterController(IOFHandler controller)
public static java.util.Set<IOFHandler> getHandlersFor(Connection conn)
void shutdown()
void addClient(java.nio.channels.SocketChannel client)
void wakeup()
public void run()
run
in interface java.lang.Runnable
run
in class java.lang.Thread
private boolean handleConnectedEvent(Connection conn)
private boolean handleReadEvent(Connection conn)
private void handleDisconnectedEvent(Connection conn)