Package org.picocontainer.lifecycle
Interface LifecycleState
- All Known Implementing Classes:
DefaultLifecycleState
public interface LifecycleState
Current lifecycle state of the container.
- Author:
- Michael Rimov, Paul Hammant
-
Method Summary
Modifier and TypeMethodDescriptionvoiddisposed()Turns the lifecycle state to completely disposed.voidTurns the lifecycle state to indicate that the dispose() process is being executed on the container.booleanChecks if the current lifecycle is disposed.booleanChecks if current lifecycle is started.booleanChecks if the current lifecyle is stopped.voidLifecycle state for when a component is being removed.voidstarting()Start is normally allowed if the object is constructed or already stopped.voidstopped()Lifecycle state for when stop has been completed.voidstopping()Lifecycle state for when the container is being stopped.
-
Method Details
-
removingComponent
void removingComponent()Lifecycle state for when a component is being removed. -
starting
void starting()Start is normally allowed if the object is constructed or already stopped. It is not allowed if the system is already started or disposed. -
stopping
void stopping()Lifecycle state for when the container is being stopped. (Ie, right after Picocontainer.stop() has been called, but before any components are stopped. -
stopped
void stopped()Lifecycle state for when stop has been completed. -
isStarted
boolean isStarted()Checks if current lifecycle is started.- Returns:
- true if the current container state is STARTED.
-
disposing
void disposing()Turns the lifecycle state to indicate that the dispose() process is being executed on the container. -
disposed
void disposed()Turns the lifecycle state to completely disposed. Internally called after PicoContainer.dispose() is finished. -
isDisposed
boolean isDisposed()Checks if the current lifecycle is disposed.- Returns:
- true if the current state is DISPOSED.
-
isStopped
boolean isStopped()Checks if the current lifecyle is stopped.- Returns:
- true if the current state is STOPPED;
-