public class DefaultThreadFactory extends Object implements ThreadFactory
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_PATTERN |
Constructor and Description |
---|
DefaultThreadFactory(String name,
ThreadGroup threadGroup,
int initialPriority,
String threadNamePattern,
String node,
String component)
Construct a new instance.
|
DefaultThreadFactory(ThreadGroup threadGroup,
int initialPriority,
String threadNamePattern,
String node,
String component)
Construct a new instance.
|
Modifier and Type | Method and Description |
---|---|
String |
getName() |
int |
initialPriority() |
Thread |
newThread(Runnable target) |
void |
setComponent(String component) |
void |
setNode(String node) |
ThreadGroup |
threadGroup() |
String |
threadNamePattern() |
public static final String DEFAULT_PATTERN
public DefaultThreadFactory(ThreadGroup threadGroup, int initialPriority, String threadNamePattern, String node, String component)
threadGroup
- the thread group to assign threads to by default (may be null
)initialPriority
- the initial thread priority, or null
to use the thread group's settingthreadNamePattern
- the name pattern stringpublic DefaultThreadFactory(String name, ThreadGroup threadGroup, int initialPriority, String threadNamePattern, String node, String component)
name
- the name of this thread factory (may be null
)threadGroup
- the thread group to assign threads to by default (may be null
)initialPriority
- the initial thread priority, or null
to use the thread group's settingthreadNamePattern
- the name pattern stringpublic String getName()
public void setNode(String node)
public void setComponent(String component)
public String threadNamePattern()
public ThreadGroup threadGroup()
public int initialPriority()
public Thread newThread(Runnable target)
newThread
in interface ThreadFactory
Copyright © 2021 JBoss by Red Hat. All rights reserved.