Top Inners Fields Constructors Methods
com.mchange.v2.c3p0

public final Class TaskRunnerThreadFactory

extends Object
implements ThreadFactory
Class Inheritance
All Implemented Interfaces
java.util.concurrent.ThreadFactory
Imports
com.mchange.v2.log.*, java.security.AccessController, .PrivilegedAction, java.util.concurrent.ThreadFactory

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static interface

Field Summary

Modifier and TypeField and Description
private static final TaskRunnerThreadFactory.ContextClassLoaderSetter
pack-priv TaskRunnerThreadFactory.ContextClassLoaderSetter
pack-priv int
private static final TaskRunnerThreadFactory.ContextClassLoaderSetter
private static final ClassLoader
private static final MLogger
private static final TaskRunnerThreadFactory.ContextClassLoaderSetter
pack-priv boolean
pack-priv ThreadGroup
pack-priv String

Constructor Summary

AccessConstructor and Description
public
TaskRunnerThreadFactory(String contextClassLoaderSource, boolean privilege_spawned_threads, String threadLabel, ThreadGroup threadGroup)

Method Summary

Modifier and TypeMethod and Description
private Thread
public Thread
newThread(final Runnable
a runnable to be executed by new thread instance
r
)

Implements java.util.concurrent.ThreadFactory.newThread.

Constructs a new unstarted Thread to run the given runnable.

private synchronized int
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

CALLER_CLASSLOADERback to summary
private static final TaskRunnerThreadFactory.ContextClassLoaderSetter CALLER_CLASSLOADER
contextClassLoaderSetterback to summary
pack-priv TaskRunnerThreadFactory.ContextClassLoaderSetter contextClassLoaderSetter
countback to summary
pack-priv int count
LIBRARY_CLASSLOADERback to summary
private static final TaskRunnerThreadFactory.ContextClassLoaderSetter LIBRARY_CLASSLOADER
LIBRARY_CLASSLOADER_INSTANCEback to summary
private static final ClassLoader LIBRARY_CLASSLOADER_INSTANCE
loggerback to summary
private static final MLogger logger
NO_CLASSLOADERback to summary
private static final TaskRunnerThreadFactory.ContextClassLoaderSetter NO_CLASSLOADER
privilege_spawned_threadsback to summary
pack-priv boolean privilege_spawned_threads
threadGroupback to summary
pack-priv ThreadGroup threadGroup
threadLabelback to summary
pack-priv String threadLabel

Constructor Detail

TaskRunnerThreadFactoryback to summary
public TaskRunnerThreadFactory(String contextClassLoaderSource, boolean privilege_spawned_threads, String threadLabel, ThreadGroup threadGroup)

Method Detail

createUnprivilegedback to summary
private Thread createUnprivileged(Runnable r)
newThreadback to summary
public Thread newThread(final Runnable r)

Implements java.util.concurrent.ThreadFactory.newThread.

Doc from java.util.concurrent.ThreadFactory.newThread.

Constructs a new unstarted Thread to run the given runnable.

Parameters
r:Runnable

a runnable to be executed by new thread instance

Returns:Thread

constructed thread, or null if the request to create a thread is rejected

nextCountback to summary
private synchronized int nextCount()
com.mchange.v2.c3p0 back to summary

private Interface TaskRunnerThreadFactory.ContextClassLoaderSetter


Method Summary

Modifier and TypeMethod and Description
public void

Method Detail

setback to summary
public void set(Thread t)