public static class Graceful.Shutdown extends java.lang.Object implements Graceful
FutureCallback
to indicate if shutdown is completed.
By default the FutureCallback
is returned as already completed, but the newShutdownCallback()
method
can be overloaded to return a non-completed callback that will require a Callback.succeeded()
or
Callback.failed(Throwable)
call to be completed.Graceful.Shutdown
Constructor and Description |
---|
Shutdown() |
Modifier and Type | Method and Description |
---|---|
void |
cancel() |
FutureCallback |
get() |
boolean |
isShutdown() |
protected FutureCallback |
newShutdownCallback() |
java.util.concurrent.Future<java.lang.Void> |
shutdown() |
protected FutureCallback newShutdownCallback()
public java.util.concurrent.Future<java.lang.Void> shutdown()
public boolean isShutdown()
isShutdown
in interface Graceful
public void cancel()
public FutureCallback get()
Copyright © 1995–2021 Webtide. All rights reserved.