public abstract class AbstractLifecycle extends AbstractInitializable implements Lifecycle, Named, Initializable
inited| 构造器和说明 |
|---|
AbstractLifecycle() |
| 限定符和类型 | 方法和说明 |
|---|---|
protected void |
doStart()
Subclasses must implement this method with the start behavior.
|
protected void |
doStop()
Subclasses must implement this method with the stop behavior.
|
String |
getName() |
boolean |
isRunning() |
void |
setName(String name) |
void |
shutdown() |
void |
startup() |
void |
stopAndExecute(Runnable callback) |
String |
toString() |
doInit, initclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitinitpublic void setName(String name)
public final boolean isRunning()
public final void stopAndExecute(Runnable callback)
protected void doStart()
lifecycleLock.protected void doStop()
lifecycleLock.Copyright © 2022. All rights reserved.