|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.norther.tammi.core.base.Adaptee org.norther.tammi.core.base.DefaultObjectFactory<Thread> org.norther.tammi.core.thread.DefaultThreadFactory
public class DefaultThreadFactory
A default implementation of ThreadFactory.
Field Summary |
---|
Fields inherited from class org.norther.tammi.core.base.Adaptee |
---|
ADAPTEE_NOTIF_DESCRIPTION, ADAPTEE_NOTIFICATIONS |
Constructor Summary | |
---|---|
DefaultThreadFactory()
Constructs a default thread factory. |
Method Summary | |
---|---|
Thread |
getInstance(String className,
ObjectName loader,
Object[] params,
String[] signature)
Gets an instance of a named class using a specified class loader. |
int |
getPriority()
Gets the default priority of production threads. |
boolean |
isDaemon()
Gets the daemon flag of production threads. |
Thread |
newThread(Runnable command)
|
void |
setDaemon(boolean daemon)
Sets the daemon flag of production threads. |
void |
setPriority(int priority)
Sets the default priority of production threads. |
Methods inherited from class org.norther.tammi.core.base.DefaultObjectFactory |
---|
getInstance, getInstance, getInstance, isLoaderSupported |
Methods inherited from class org.norther.tammi.core.base.Adaptee |
---|
addAdaptee, addNotificationListener, getAttributeSupport, getBroker, getCanonicalName, getDomain, getFactory, getLoader, getLog, getLog, getMBean, getMBeanServer, getNotificationInfo, getObjectName, getRegistrationTime, getSequenceNumber, hasListeners, isRegistered, postmanaged, premanaged, removeNotificationListener, removeNotificationListener, sendNotification, sendNotification, sendNotification, sendNotification, unmanaged, unregister |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.norther.tammi.core.base.ObjectFactory |
---|
getInstance, getInstance, getInstance, isLoaderSupported |
Constructor Detail |
---|
public DefaultThreadFactory()
Method Detail |
---|
public int getPriority()
ThreadFactory
public void setPriority(int priority)
ThreadFactory
priority
- the default priority.public boolean isDaemon()
ThreadFactory
public void setDaemon(boolean daemon)
ThreadFactory
daemon
- the daemon flag.public Thread getInstance(String className, ObjectName loader, Object[] params, String[] signature) throws ConstructionException
ObjectFactory
Class loaders are supported only if the isLoaderSupported method returns true. Otherwise the loader parameter is ignored.
getInstance
in interface ObjectFactory<Thread>
getInstance
in class DefaultObjectFactory<Thread>
className
- the name of the class.loader
- the class loader.params
- an array containing the parameters of the constructor.signature
- an array containing the signature of the constructor.
ConstructionException
- if construction fails.public Thread newThread(Runnable command)
newThread
in interface ThreadFactory
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |