org.snmp4j.util
Class DefaultThreadFactory

java.lang.Object
  extended by org.snmp4j.util.DefaultThreadFactory
All Implemented Interfaces:
ThreadFactory

public class DefaultThreadFactory
extends java.lang.Object
implements ThreadFactory


Nested Class Summary
 class DefaultThreadFactory.WorkerThread
           
 
Constructor Summary
DefaultThreadFactory()
           
 
Method Summary
 WorkerTask createWorkerThread(java.lang.String name, WorkerTask task, boolean daemon)
          Creates a new thread of execution for the supplied task.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultThreadFactory

public DefaultThreadFactory()
Method Detail

createWorkerThread

public WorkerTask createWorkerThread(java.lang.String name,
                                     WorkerTask task,
                                     boolean daemon)
Creates a new thread of execution for the supplied task.

Specified by:
createWorkerThread in interface ThreadFactory
Parameters:
name - the name of the execution thread.
task - the task to be executed in the new thread.
daemon - indicates whether the new thread is a daemon (true or an user thread (false).
Returns:
the WorkerTask wrapper to control start and termination of the thread.

Copyright 2003-2009 Frank Fock and Jochen Katz (SNMP4J.org)