public class DispatcherThread extends Thread
Thread.State, Thread.UncaughtExceptionHandler| Modifier and Type | Field and Description |
|---|---|
static BackOffStrategy |
backOffStrategy
defines the strategy applied when idling
|
static int |
DEFAULT_QUEUE_SIZE |
static AtomicInteger |
instanceCount |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY| Constructor and Description |
|---|
DispatcherThread() |
DispatcherThread(int qSize) |
| Modifier and Type | Method and Description |
|---|---|
void |
actorAdded(Actor a) |
void |
actorStopped(Actor a) |
boolean |
dispatchCallback(CallEntry ce) |
boolean |
dispatchOnObject(CallEntry entry) |
InvocationHandler |
getInvoker(Object toWrap) |
int |
getQSize() |
static DispatcherThread |
getThreadDispatcher() |
protected void |
init(int qSize) |
boolean |
isEmpty() |
boolean |
isShutDown() |
static Future |
pollDispatchOnObject(DispatcherThread currentThreadDispatcher,
CallEntry e) |
boolean |
pollQs() |
void |
run() |
void |
shutDown()
terminate operation after emptying Q
|
void |
shutDownImmediate()
terminate operation immediately.
|
String |
toString() |
void |
waitEmpty(long nanos)
blocking method, use for debugging only.
|
static void |
yield(int count) |
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, yieldpublic static AtomicInteger instanceCount
public static BackOffStrategy backOffStrategy
public static int DEFAULT_QUEUE_SIZE
public DispatcherThread()
public DispatcherThread(int qSize)
public boolean isEmpty()
public InvocationHandler getInvoker(Object toWrap)
protected void init(int qSize)
public void actorAdded(Actor a)
public void actorStopped(Actor a)
public static Future pollDispatchOnObject(DispatcherThread currentThreadDispatcher, CallEntry e)
public boolean dispatchOnObject(CallEntry entry)
public boolean dispatchCallback(CallEntry ce)
public static DispatcherThread getThreadDispatcher()
public boolean pollQs()
public static void yield(int count)
public int getQSize()
public boolean isShutDown()
public void shutDown()
public void shutDownImmediate()
public void waitEmpty(long nanos)
Copyright © 2014. All rights reserved.