Get a ThreadFactory suitable for use in the current environment. @param nameFormat to apply to threads created by the factory. @param daemon true if the threads the factory creates are daemon threads, false otherwise. @return a ThreadFactory.
(String nameFormat, boolean daemon)
| 620 | * @return a {@link ThreadFactory}. |
| 621 | */ |
| 622 | public static ThreadFactory getThreadFactory(String nameFormat, boolean daemon) { |
| 623 | return new ThreadFactoryBuilder() |
| 624 | .setDaemon(daemon) |
| 625 | .setNameFormat(nameFormat) |
| 626 | .build(); |
| 627 | } |
| 628 | |
| 629 | /** |
| 630 | * The factory of default Stopwatches. |
no test coverage detected