Package io.netty.util.concurrent
Class FastThreadLocalThread
- java.lang.Object
-
- java.lang.Thread
-
- io.netty.util.concurrent.FastThreadLocalThread
-
- All Implemented Interfaces:
java.lang.Runnable
public class FastThreadLocalThread extends java.lang.Thread
A specialThread
that provides fast access toFastThreadLocal
variables.
-
-
Field Summary
Fields Modifier and Type Field Description private boolean
cleanupFastThreadLocals
private InternalThreadLocalMap
threadLocalMap
-
Constructor Summary
Constructors Constructor Description FastThreadLocalThread()
FastThreadLocalThread(java.lang.Runnable target)
FastThreadLocalThread(java.lang.Runnable target, java.lang.String name)
FastThreadLocalThread(java.lang.String name)
FastThreadLocalThread(java.lang.ThreadGroup group, java.lang.Runnable target)
FastThreadLocalThread(java.lang.ThreadGroup group, java.lang.Runnable target, java.lang.String name)
FastThreadLocalThread(java.lang.ThreadGroup group, java.lang.Runnable target, java.lang.String name, long stackSize)
FastThreadLocalThread(java.lang.ThreadGroup group, java.lang.String name)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
setThreadLocalMap(InternalThreadLocalMap threadLocalMap)
Sets the internal data structure that keeps the thread-local variables bound to this thread.InternalThreadLocalMap
threadLocalMap()
Returns the internal data structure that keeps the thread-local variables bound to this thread.boolean
willCleanupFastThreadLocals()
static boolean
willCleanupFastThreadLocals(java.lang.Thread thread)
-
Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, onSpinWait, resume, run, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, suspend, toString, yield
-
-
-
-
Field Detail
-
cleanupFastThreadLocals
private final boolean cleanupFastThreadLocals
-
threadLocalMap
private InternalThreadLocalMap threadLocalMap
-
-
Constructor Detail
-
FastThreadLocalThread
public FastThreadLocalThread()
-
FastThreadLocalThread
public FastThreadLocalThread(java.lang.Runnable target)
-
FastThreadLocalThread
public FastThreadLocalThread(java.lang.ThreadGroup group, java.lang.Runnable target)
-
FastThreadLocalThread
public FastThreadLocalThread(java.lang.String name)
-
FastThreadLocalThread
public FastThreadLocalThread(java.lang.ThreadGroup group, java.lang.String name)
-
FastThreadLocalThread
public FastThreadLocalThread(java.lang.Runnable target, java.lang.String name)
-
FastThreadLocalThread
public FastThreadLocalThread(java.lang.ThreadGroup group, java.lang.Runnable target, java.lang.String name)
-
FastThreadLocalThread
public FastThreadLocalThread(java.lang.ThreadGroup group, java.lang.Runnable target, java.lang.String name, long stackSize)
-
-
Method Detail
-
threadLocalMap
public final InternalThreadLocalMap threadLocalMap()
Returns the internal data structure that keeps the thread-local variables bound to this thread. Note that this method is for internal use only, and thus is subject to change at any time.
-
setThreadLocalMap
public final void setThreadLocalMap(InternalThreadLocalMap threadLocalMap)
Sets the internal data structure that keeps the thread-local variables bound to this thread. Note that this method is for internal use only, and thus is subject to change at any time.
-
willCleanupFastThreadLocals
@UnstableApi public boolean willCleanupFastThreadLocals()
-
willCleanupFastThreadLocals
@UnstableApi public static boolean willCleanupFastThreadLocals(java.lang.Thread thread)
-
-