public abstract class AbstractIOSelector extends Thread implements IOSelector
Thread.State, Thread.UncaughtExceptionHandler
Modifier and Type | Field and Description |
---|---|
protected boolean |
live |
protected ILogger |
logger |
protected Selector |
selector |
protected Queue<Runnable> |
selectorQueue |
protected int |
waitTime |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
Constructor and Description |
---|
AbstractIOSelector(ThreadGroup threadGroup,
String tname,
ILogger logger,
IOSelectorOutOfMemoryHandler oomeHandler) |
Modifier and Type | Method and Description |
---|---|
void |
addTask(Runnable runnable) |
void |
awaitShutdown() |
Selector |
getSelector() |
protected abstract void |
handleSelectionKey(SelectionKey sk) |
void |
run() |
void |
shutdown() |
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
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
start
protected final ILogger logger
protected final int waitTime
protected final Selector selector
protected boolean live
public AbstractIOSelector(ThreadGroup threadGroup, String tname, ILogger logger, IOSelectorOutOfMemoryHandler oomeHandler)
public final void shutdown()
shutdown
in interface IOSelector
public final void awaitShutdown()
awaitShutdown
in interface IOSelector
public final void addTask(Runnable runnable)
addTask
in interface IOSelector
protected abstract void handleSelectionKey(SelectionKey sk)
public final Selector getSelector()
getSelector
in interface IOSelector
public final void wakeup()
wakeup
in interface IOSelector
Copyright © 2014 Hazelcast, Inc.. All Rights Reserved.