Code example for AtomicLong

Methods: incrementAndGet

0
 *         </a> 
 */ 
public class TimerThreadFactory implements ThreadFactory {
	public static final int _DEFAULT_T_PRIORITY = Thread.MAX_PRIORITY;
	public static final AtomicLong sequence = new AtomicLong(0);
	private ThreadGroup factoryThreadGroup = new ThreadGroup("MMSToolClockThreadGroup[" + sequence.incrementAndGet() + "]");
 
	public Thread newThread(Runnable r) {
		Thread t = new Thread(this.factoryThreadGroup, r);
		t.setPriority(_DEFAULT_T_PRIORITY);
		// ?? 
		//t.start(); 
		return t;
	} 
}