Class ThreadFactoryBuilder

java.lang.Object
com.google.common.util.concurrent.ThreadFactoryBuilder

@GwtIncompatible public final class ThreadFactoryBuilder extends Object
A ThreadFactory builder, providing any combination of these features:

If no backing thread factory is provided, a default backing thread factory is used as if by calling setThreadFactory(Executors.defaultThreadFactory()).

Java 21+ users: consider using the Thread.Builder interface instead. E.g., instead of new ThreadFactoryBuilder().setPriority(priority).setDaemon(false).build(), use Thread.ofPlatform().priority(priority).daemon(false).factory().

Since:
4.0
Author:
Kurt Alfred Kluever