View Javadoc
1   package com.jsql.model.suspendable.callable;
2   
3   import java.util.concurrent.ThreadFactory;
4   
5   public class ThreadFactoryCallable implements ThreadFactory {
6       
7       private final String nameThread;
8       
9       public ThreadFactoryCallable(String nameThread) {
10          this.nameThread = nameThread;
11      }
12      
13      @Override
14      public Thread newThread(Runnable runnable) {
15          return new Thread(runnable, this.nameThread);
16      }
17  }