public abstract class AbstractLifecycle
extends java.lang.Object
Constructor and Description |
---|
AbstractLifecycle() |
Modifier and Type | Method and Description |
---|---|
boolean |
isRunning() |
protected abstract void |
onShutdown() |
protected abstract void |
onStartup() |
void |
shutdown()
Call to shut this thing down.
|
void |
startup()
Call to start this thing up.
|
public final void startup()
onStartup()
will be called. Subsequent
invocations will throw an IllegalStateException
protected abstract void onStartup()
public final void shutdown()
protected abstract void onShutdown()
public boolean isRunning()
startup()
is called and before shutdown()
is called.