public final class DefaultFixedThreadsExecutorGroup extends Object implements FixedThreadsExecutorGroup
| 构造器和说明 |
|---|
DefaultFixedThreadsExecutorGroup(ExecutorService[] executors) |
DefaultFixedThreadsExecutorGroup(ExecutorService[] executors,
ExecutorChooserFactory.ExecutorChooser chooser) |
DefaultFixedThreadsExecutorGroup(SingleThreadExecutor[] children) |
DefaultFixedThreadsExecutorGroup(SingleThreadExecutor[] children,
ExecutorChooserFactory.ExecutorChooser chooser) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
execute(int index,
Runnable task)
Executes the given task at some time in the future.
|
Iterator<SingleThreadExecutor> |
iterator() |
SingleThreadExecutor |
next()
Returns one of the
SingleThreadExecutors managed by this
FixedThreadsExecutorGroup. |
boolean |
shutdownGracefully()
Shortcut method for
FixedThreadsExecutorGroup.shutdownGracefully(long, TimeUnit) with
sensible default values. |
boolean |
shutdownGracefully(long timeout,
TimeUnit unit)
Signals all executors that the caller wants them to be shutdown.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorpublic DefaultFixedThreadsExecutorGroup(SingleThreadExecutor[] children)
public DefaultFixedThreadsExecutorGroup(SingleThreadExecutor[] children, ExecutorChooserFactory.ExecutorChooser chooser)
public DefaultFixedThreadsExecutorGroup(ExecutorService[] executors)
public DefaultFixedThreadsExecutorGroup(ExecutorService[] executors, ExecutorChooserFactory.ExecutorChooser chooser)
public SingleThreadExecutor next()
FixedThreadsExecutorGroupSingleThreadExecutors managed by this
FixedThreadsExecutorGroup.next 在接口中 FixedThreadsExecutorGrouppublic void execute(int index,
Runnable task)
FixedThreadsExecutorGroupexecute 在接口中 FixedThreadsExecutorGroupindex - index for thread choosertask - the runnable taskpublic boolean shutdownGracefully()
FixedThreadsExecutorGroupFixedThreadsExecutorGroup.shutdownGracefully(long, TimeUnit) with
sensible default values.shutdownGracefully 在接口中 FixedThreadsExecutorGrouppublic boolean shutdownGracefully(long timeout,
TimeUnit unit)
FixedThreadsExecutorGroupshutdownGracefully 在接口中 FixedThreadsExecutorGrouptimeout - the maximum amount of time to wait until the executor
is shutdownunit - the unit of timeoutpublic Iterator<SingleThreadExecutor> iterator()
iterator 在接口中 Iterable<SingleThreadExecutor>Copyright © 2021. All rights reserved.