Package org.activiti.spring
Class AbstractActivitiSmartLifeCycle
- java.lang.Object
-
- org.activiti.spring.AbstractActivitiSmartLifeCycle
-
- All Implemented Interfaces:
org.springframework.beans.factory.DisposableBean,org.springframework.context.Lifecycle,org.springframework.context.Phased,org.springframework.context.SmartLifecycle
- Direct Known Subclasses:
ProcessDeployedEventProducer,StartMessageDeployedEventProducer
public abstract class AbstractActivitiSmartLifeCycle extends java.lang.Object implements org.springframework.context.SmartLifecycle, org.springframework.beans.factory.DisposableBean
-
-
Constructor Summary
Constructors Constructor Description AbstractActivitiSmartLifeCycle()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voiddestroy()abstract voiddoStart()abstract voiddoStop()intgetPhase()Return the phase in which this component will be started and stopped.booleanisAutoStartup()Return the value for the 'autoStartup' property.booleanisRunning()voidsetAutoStartup(boolean autoStartup)Set whether to auto-start the activation after this component has been initialized and the context has been refreshed.voidsetPhase(int phase)Specify the phase in which this component should be started and stopped.voidstart()voidstop()voidstop(java.lang.Runnable callback)
-
-
-
Method Detail
-
doStart
public abstract void doStart()
-
doStop
public abstract void doStop()
-
setAutoStartup
public void setAutoStartup(boolean autoStartup)
Set whether to auto-start the activation after this component has been initialized and the context has been refreshed.Default is "true". Turn this flag off to defer the endpoint activation until an explicit
start()call.
-
isAutoStartup
public boolean isAutoStartup()
Return the value for the 'autoStartup' property. If "true", this component will start upon a ContextRefreshedEvent.- Specified by:
isAutoStartupin interfaceorg.springframework.context.SmartLifecycle
-
setPhase
public void setPhase(int phase)
Specify the phase in which this component should be started and stopped. The startup order proceeds from lowest to highest, and the shutdown order is the reverse of that. By default this value is Integer.MAX_VALUE meaning that this component starts as late as possible and stops as soon as possible.
-
getPhase
public int getPhase()
Return the phase in which this component will be started and stopped.- Specified by:
getPhasein interfaceorg.springframework.context.Phased- Specified by:
getPhasein interfaceorg.springframework.context.SmartLifecycle
-
start
public void start()
- Specified by:
startin interfaceorg.springframework.context.Lifecycle
-
stop
public void stop()
- Specified by:
stopin interfaceorg.springframework.context.Lifecycle
-
stop
public void stop(java.lang.Runnable callback)
- Specified by:
stopin interfaceorg.springframework.context.SmartLifecycle
-
isRunning
public boolean isRunning()
- Specified by:
isRunningin interfaceorg.springframework.context.Lifecycle
-
destroy
public void destroy()
- Specified by:
destroyin interfaceorg.springframework.beans.factory.DisposableBean
-
-