类 CustomizableThreadFactory
- java.lang.Object
- org.springframework.util.CustomizableThreadCreator
- org.springframework.scheduling.concurrent.CustomizableThreadFactory
- 所有已实现的接口:
Serializable,ThreadFactory
public class CustomizableThreadFactory extends CustomizableThreadCreator implements ThreadFactory
Implementation of theThreadFactoryinterface, allowing for customizing the created threads (name, priority, etc).See the base class
CustomizableThreadCreatorfor details on the available configuration options.- 从以下版本开始:
- 2.0.3
- 作者:
- Juergen Hoeller
- 另请参阅:
CustomizableThreadCreator.setThreadNamePrefix(java.lang.String),CustomizableThreadCreator.setThreadPriority(int), 序列化表格
构造器概要
构造器 构造器 说明 CustomizableThreadFactory()Create a new CustomizableThreadFactory with default thread name prefix.CustomizableThreadFactory(String threadNamePrefix)Create a new CustomizableThreadFactory with the given thread name prefix.
方法概要
从类继承的方法 org.springframework.util.CustomizableThreadCreator
createThread, getDefaultThreadNamePrefix, getThreadGroup, getThreadNamePrefix, getThreadPriority, isDaemon, nextThreadName, setDaemon, setThreadGroup, setThreadGroupName, setThreadNamePrefix, setThreadPriority
构造器详细资料
CustomizableThreadFactory
public CustomizableThreadFactory()
Create a new CustomizableThreadFactory with default thread name prefix.
CustomizableThreadFactory
public CustomizableThreadFactory(String threadNamePrefix)
Create a new CustomizableThreadFactory with the given thread name prefix.- 参数:
threadNamePrefix- the prefix to use for the names of newly created threads
方法详细资料
newThread
public Thread newThread(Runnable runnable)
- 指定者:
newThread在接口中ThreadFactory