public abstract class LifecycleObjectSupport extends java.lang.Object implements org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.DisposableBean, org.springframework.context.SmartLifecycle, org.springframework.beans.factory.BeanFactoryAware, StateMachineReactiveLifecycle
Constructor and Description |
---|
LifecycleObjectSupport() |
Modifier and Type | Method and Description |
---|---|
void |
afterPropertiesSet() |
void |
destroy() |
protected void |
doDestroy()
Subclasses may implement this for destroy logic.
|
protected reactor.core.publisher.Mono<java.lang.Void> |
doPostStartReactively()
Subclasses may implement this for post start logic.
|
protected reactor.core.publisher.Mono<java.lang.Void> |
doPostStopReactively()
Subclasses may implement this for post stop logic.
|
protected reactor.core.publisher.Mono<java.lang.Void> |
doPreStartReactively()
Subclasses may implement this for pre start logic.
|
protected reactor.core.publisher.Mono<java.lang.Void> |
doPreStopReactively()
Subclasses may implement this for pre stop logic.
|
protected org.springframework.beans.factory.BeanFactory |
getBeanFactory()
Gets the
BeanFactory for this instance. |
int |
getPhase() |
boolean |
isAutoStartup() |
boolean |
isRunning() |
protected void |
onInit()
Subclasses may implement this for initialization logic.
|
void |
setAutoStartup(boolean autoStartup)
Sets the auto startup.
|
void |
setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory) |
void |
setPhase(int phase)
Sets the phase.
|
void |
start() |
reactor.core.publisher.Mono<java.lang.Void> |
startReactively()
Starts component reactively.
|
void |
stop() |
reactor.core.publisher.Mono<java.lang.Void> |
stopReactively()
Stops component reactively.
|
public final void afterPropertiesSet()
afterPropertiesSet
in interface org.springframework.beans.factory.InitializingBean
public final void destroy() throws java.lang.Exception
destroy
in interface org.springframework.beans.factory.DisposableBean
java.lang.Exception
public void setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory) throws org.springframework.beans.BeansException
setBeanFactory
in interface org.springframework.beans.factory.BeanFactoryAware
org.springframework.beans.BeansException
public final boolean isAutoStartup()
isAutoStartup
in interface org.springframework.context.SmartLifecycle
public final int getPhase()
getPhase
in interface org.springframework.context.Phased
getPhase
in interface org.springframework.context.SmartLifecycle
public void start()
start
in interface org.springframework.context.Lifecycle
public void stop()
stop
in interface org.springframework.context.Lifecycle
public reactor.core.publisher.Mono<java.lang.Void> startReactively()
StateMachineReactiveLifecycle
startReactively
in interface StateMachineReactiveLifecycle
public reactor.core.publisher.Mono<java.lang.Void> stopReactively()
StateMachineReactiveLifecycle
stopReactively
in interface StateMachineReactiveLifecycle
public boolean isRunning()
isRunning
in interface org.springframework.context.Lifecycle
public void setAutoStartup(boolean autoStartup)
autoStartup
- the new auto startupSmartLifecycle
public void setPhase(int phase)
phase
- the new phaseSmartLifecycle
protected final org.springframework.beans.factory.BeanFactory getBeanFactory()
BeanFactory
for this instance.protected void onInit() throws java.lang.Exception
InitializingBean
phase.java.lang.Exception
- exceptionprotected void doDestroy()
protected reactor.core.publisher.Mono<java.lang.Void> doPreStartReactively()
protected reactor.core.publisher.Mono<java.lang.Void> doPreStopReactively()
protected reactor.core.publisher.Mono<java.lang.Void> doPostStartReactively()
protected reactor.core.publisher.Mono<java.lang.Void> doPostStopReactively()