|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public static interface ConcurrencyTools.Shutdownable
A Shutdownable is an execution resource than can be shutdown
for termination.
Shutdownable is to execution resources as Closeable is to I/O resources.
This type is the result of applying the "Extract Interface"
refactoring to the portion of ExecutorService concerned with shutdown and
termination.
ExecutorService| Nested Class Summary | |
|---|---|
static class |
ConcurrencyTools.Shutdownable.ShutdownClosingPolicy
Specifies the policy to execute when shutdown() is
called. |
| Method Summary | |
|---|---|
boolean |
awaitTermination(long timeout,
TimeUnit unit)
|
boolean |
isShutdown()
|
boolean |
isTerminated()
|
void |
shutdown()
"Gracefully" shuts down the execution resources held by this Shutdownable. |
List<Runnable> |
shutdownNow()
Abruptly shuts down the execution resources held by this Shutdownable. |
| Method Detail |
|---|
void shutdown()
Shutdownable.
InterruptedException - Iff the execution resources held by this Shutdownable
could not be shutdown. Subtypes are free to specify whether
subsequent invocations of shutdown() may succeed
after a failed invocation.ExecutorServiceList<Runnable> shutdownNow()
Shutdownable. Think "kill -9".
InterruptedException - Iff the execution resources held by this Shutdownable
could not be shutdown. Subtypes are free to specify whether
subsequent invocations of shutdown() may succeed
after a failed invocation.ExecutorServiceboolean isShutdown()
ExecutorServiceboolean isTerminated()
ExecutorService
boolean awaitTermination(long timeout,
TimeUnit unit)
ExecutorService
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||