org.mortbay.component
Interface LifeCycle

All Known Subinterfaces:
Connector, Handler, RequestLog, SessionManager, SessionManager.MetaManager, ThreadPool
All Known Implementing Classes:
AbstractConnector, AbstractHandler, AbstractLifeCycle, AbstractSessionManager, AbstractSessionManager.NullMetaManager, AbstractSessionManager.SimpleMetaManager, BlockingChannelConnector, BoundedThreadPool, ContextHandler, ErrorHandler, FilterHolder, HandlerCollection, HashSessionManager, Holder, IO, NCSARequestLog, NotFoundHandler, RequestLogHandler, ResourceCache, SecurityHandler, SelectBlockingChannelConnector, SelectChannelConnector, Server, ServletHandler, ServletHolder, SessionHandler, SocketConnector, SslSocketConnector, WebAppContext, WebAppContext.WebAppErrorHandler, WrappedHandler

public interface LifeCycle

A component LifeCycle. Represents the life cycle interface for an abstract software component.

Author:
Greg Wilkins (gregw)

Method Summary
 boolean isFailed()
           
 boolean isRunning()
           
 boolean isStarted()
           
 boolean isStarting()
           
 boolean isStopping()
           
 void start()
          Start the LifeCycle.
 void stop()
          Stop the LifeCycle.
 

Method Detail

start

void start()
           throws Exception
Start the LifeCycle.

Throws:
Exception - An arbitrary exception may be thrown.

stop

void stop()
          throws Exception
Stop the LifeCycle. The LifeCycle may wait for current activities to complete normally, but it can be interrupted.

Throws:
Exception - An arbitrary exception may be thrown.

isRunning

boolean isRunning()
Returns:
True if the LifeCycle is starting or has been started.

isStarted

boolean isStarted()
Returns:
True if the LifeCycle has been started.

isStarting

boolean isStarting()
Returns:
True if the LifeCycle is starting.

isStopping

boolean isStopping()
Returns:
True if the LifeCycle is stopping

isFailed

boolean isFailed()
Returns:
True if the LifeCycle is failed