public class DefaultLifecycleAdapter extends Object implements LifecycleAdapter
DefaultLifecycleAdapter provides lifecycle methods for all Mule
managed components. It's possible to plugin custom lifecycle adapters, this can
provide additional lifecycle methods triggered by an external source.| Modifier and Type | Field and Description |
|---|---|
protected JavaComponent |
component |
protected Object |
componentObject |
protected static org.apache.commons.logging.Log |
logger
logger used by this class
|
PHASE_NAMEPHASE_NAMEPHASE_NAMEPHASE_NAME| Constructor and Description |
|---|
DefaultLifecycleAdapter(Object componentObject,
JavaComponent component) |
DefaultLifecycleAdapter(Object componentObject,
JavaComponent component,
EntryPointResolverSet entryPointResolver) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
configureNestedRouter() |
void |
dispose()
Propagates dispose() life-cycle to component object implementations if they
implement the mule
Disposable interface. |
void |
initialise()
Propagates initialise() life-cycle to component object implementations if they
implement the mule
Initialisable interface. |
MuleMessage |
intercept(Invocation invocation)
Invoked when the component should be called.
|
boolean |
isDisposed() |
boolean |
isStarted() |
void |
start()
Propagates start() life-cycle to component object implementations if they
implement the mule
Startable interface. |
void |
stop()
Propagates stop() life-cycle to component object implementations if they
implement the mule
Stoppable interface. |
protected static final org.apache.commons.logging.Log logger
protected Object componentObject
protected JavaComponent component
public DefaultLifecycleAdapter(Object componentObject, JavaComponent component) throws MuleException
MuleExceptionpublic DefaultLifecycleAdapter(Object componentObject, JavaComponent component, EntryPointResolverSet entryPointResolver) throws MuleException
MuleExceptionpublic void start()
throws MuleException
Startable interface. NOT: It is up to component
implementations to ensure their implementation of start() is thread-safe.start in interface StartableMuleExceptionpublic void stop()
throws MuleException
Stoppable interface. NOT: It is up to component
implementations to ensure their implementation of stop() is thread-safe.stop in interface StoppableMuleExceptionpublic void dispose()
Disposable interface. NOT: It is up to component
implementations to ensure their implementation of dispose() is thread-safe.dispose in interface Disposablepublic boolean isStarted()
isStarted in interface LifecycleAdapterpublic boolean isDisposed()
isDisposed in interface LifecycleAdapterpublic MuleMessage intercept(Invocation invocation) throws MuleException
InterceptorInvocation.execute() to call the component.intercept in interface Interceptorinvocation - the invocation containing info about the current message and
serviceMuleException - if the invocation failspublic void initialise()
throws InitialisationException
Initialisable interface.
NOTE: It is up to component implementations to ensure their implementation of
initialise() is thread-safe.initialise in interface InitialisableInitialisationException - if a fatal error occurs causing the Mule instance to shutdownRecoverableException - if an error occurs that can be recovered fromprotected void configureNestedRouter()
throws MuleException
MuleExceptionCopyright © 2003-2012 MuleSource, Inc.. All Rights Reserved.