Most visited

Recently visited

Added in API level 21

ForkJoinPool.ForkJoinWorkerThreadFactory

public static interface ForkJoinPool.ForkJoinWorkerThreadFactory

java.util.concurrent.ForkJoinPool.ForkJoinWorkerThreadFactory


用于创建新的ForkJoinWorkerThread s的工厂。 ForkJoinWorkerThreadFactory必须定义并用于扩展基本功能的ForkJoinWorkerThread子类或使用不同上下文初始化线程。

Summary

Public methods

abstract ForkJoinWorkerThread newThread(ForkJoinPool pool)

返回在给定池中运行的新工作线程。

Public methods

newThread

Added in API level 21
ForkJoinWorkerThread newThread (ForkJoinPool pool)

返回在给定池中运行的新工作线程。

Parameters
pool ForkJoinPool: the pool this thread works in
Returns
ForkJoinWorkerThread the new worker thread, or null if the request to create a thread is rejected
Throws
NullPointerException if the pool is null

Hooray!