org.apache.felix.ipojo.extender.internal.queue

## Class PrefixedThreadFactory

- java.lang.Object
- - org.apache.felix.ipojo.extender.internal.queue.PrefixedThreadFactory

All Implemented Interfaces:
  java.util.concurrent.ThreadFactory

    public class PrefixedThreadFactory
    extends java.lang.Object
    implements java.util.concurrent.ThreadFactory

A thread factory setting the name of the created thread. This thread factory delegates the thread creation on another factory, it just set the thread name (actually just set a prefix).

### Constructor Summary

Constructors
Constructor and Description
`PrefixedThreadFactory(java.lang.String prefix)` Creates the object using the default thread factory.
`PrefixedThreadFactory(java.util.concurrent.ThreadFactory threadFactory, java.lang.String prefix)` Creates the object delegating to the given thread factory.

### Method Summary

All Methods Instance Methods Concrete Methods
`java.lang.Thread` `newThread(java.lang.Runnable r)` Creates a new thread.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### PrefixedThreadFactory

    public PrefixedThreadFactory(java.lang.String prefix)

Creates the object using the default thread factory.

Parameters:
  `prefix` - the prefix

#### PrefixedThreadFactory

    public PrefixedThreadFactory(java.util.concurrent.ThreadFactory threadFactory,
                                 java.lang.String prefix)

Creates the object delegating to the given thread factory.

Parameters:
  `threadFactory` - the thread factory
  `prefix` - the prefix

### Method Detail

#### newThread

    public java.lang.Thread newThread(java.lang.Runnable r)

Creates a new thread. Prepend the prefix to the thread name

Specified by:
  `newThread` in interface `java.util.concurrent.ThreadFactory`
Parameters:
  `r` - the runnable
Returns:
  the thread object