org.apache.camel.component.servletlistener
Interface CamelContextLifecycle<R extends org.apache.camel.spi.Registry>

Type Parameters:
R - the type of the Registry being used by this callback

public interface CamelContextLifecycle<R extends org.apache.camel.spi.Registry>

A callback lifecycle allows end users to implement custom logic before the ServletCamelContext is started and stopped.


Method Summary
 void afterAddRoutes(ServletCamelContext camelContext, R registry)
          Callback after adding the routes.
 void afterStart(ServletCamelContext camelContext, R registry)
          Callback after ServletCamelContext has been started.
 void afterStop(ServletCamelContext camelContext, R registry)
          Callback after ServletCamelContext has been stopped.
 void beforeAddRoutes(ServletCamelContext camelContext, R registry)
          Callback before adding the routes.
 void beforeStart(ServletCamelContext camelContext, R registry)
          Callback before starting ServletCamelContext.
 void beforeStop(ServletCamelContext camelContext, R registry)
          Callback before stopping ServletCamelContext.
 

Method Detail

beforeStart

void beforeStart(ServletCamelContext camelContext,
                 R registry)
                 throws Exception
Callback before starting ServletCamelContext.

Parameters:
camelContext - the Camel context
registry - the registry
Throws:
Exception - is thrown if any error.

afterStart

void afterStart(ServletCamelContext camelContext,
                R registry)
                throws Exception
Callback after ServletCamelContext has been started.

Parameters:
camelContext - the Camel context
registry - the registry
Throws:
Exception - is thrown if any error.

beforeStop

void beforeStop(ServletCamelContext camelContext,
                R registry)
                throws Exception
Callback before stopping ServletCamelContext.

Parameters:
camelContext - the Camel context
registry - the registry
Throws:
Exception - is thrown if any error.

afterStop

void afterStop(ServletCamelContext camelContext,
               R registry)
               throws Exception
Callback after ServletCamelContext has been stopped.

Parameters:
camelContext - the Camel context
registry - the registry
Throws:
Exception - is thrown if any error.

beforeAddRoutes

void beforeAddRoutes(ServletCamelContext camelContext,
                     R registry)
                     throws Exception
Callback before adding the routes.

Parameters:
camelContext - the Camel context
registry - the registry
Throws:
Exception - is thrown if any error.

afterAddRoutes

void afterAddRoutes(ServletCamelContext camelContext,
                    R registry)
                    throws Exception
Callback after adding the routes.

Parameters:
camelContext - the Camel context
registry - the registry
Throws:
Exception - is thrown if any error.


Apache Camel