ThreadPoolExecutor.this
- this(int corePoolSize, int maximumPoolSize, Duration keepAliveTime, BlockingQueue!(Runnable) workQueue)
- this(int corePoolSize, int maximumPoolSize, Duration keepAliveTime, BlockingQueue!(Runnable) workQueue, ThreadFactory threadFactory)
- this(int corePoolSize, int maximumPoolSize, Duration keepAliveTime, BlockingQueue!(Runnable) workQueue, RejectedExecutionHandler handler)
- this(int corePoolSize, int maximumPoolSize, Duration keepAliveTime, BlockingQueue!(Runnable) workQueue, ThreadFactory threadFactory, RejectedExecutionHandler handler)
Creates a new {@code ThreadPoolExecutor} with the given initial parameters and {@linkplain ThreadPoolExecutor.AbortPolicy default rejected execution handler}.
@param corePoolSize the number of threads to keep in the pool, even if they are idle, unless {@code allowCoreThreadTimeOut} is set @param maximumPoolSize the maximum number of threads to allow in the pool @param keepAliveTime when the number of threads is greater than the core, this is the maximum time that excess idle threads will wait for new tasks before terminating. @param workQueue the queue to use for holding tasks before they are executed. This queue will hold only the {@code Runnable} tasks submitted by the {@code execute} method. @param threadFactory the factory to use when the executor creates a new thread @throws IllegalArgumentException if one of the following holds:<br> {@code corePoolSize < 0}<br> {@code keepAliveTime < 0}<br> {@code maximumPoolSize <= 0}<br> {@code maximumPoolSize < corePoolSize} @throws NullPointerException if {@code workQueue} or {@code threadFactory} is null