final class NonSharedThreadPoolStrategy extends AbstractThreadPoolStrategy
AbstractThreadPoolStrategy
Constructor and Description |
---|
NonSharedThreadPoolStrategy(ConsoleStream logger,
java.util.concurrent.ExecutorService threadPool) |
Modifier and Type | Method and Description |
---|---|
boolean |
finished()
Waiting for scheduled tasks to finish.
|
boolean |
hasSharedThreadPool() |
destroy, getFutureResults, getThreadPool, schedule, setDefaultShutdownHandler, stop, stopNow
canSchedule, disable, logQuietly
NonSharedThreadPoolStrategy(ConsoleStream logger, java.util.concurrent.ExecutorService threadPool)
public boolean hasSharedThreadPool()
hasSharedThreadPool
in class SchedulingStrategy
true
if a thread pool associated with this strategy
can be shared with other strategies.public boolean finished() throws java.lang.InterruptedException
SchedulingStrategy
finished
in class SchedulingStrategy
true
if successfully stopped the scheduler, else
false
if already stopped (a shared thread
pool was shutdown externally).java.lang.InterruptedException
- if interrupted while waiting
for scheduled tasks to finishRunnerScheduler.finished()