org.apache.catalina.util
Class LifecycleSupport
java.lang.Object
org.apache.catalina.util.LifecycleSupport
public final class LifecycleSupport
extends java.lang.Object
Support class to assist in firing LifecycleEvent notifications to
registered LifecycleListeners.
Version:
- Craig R. McClanahan
LifecycleSupport(Lifecycle lifecycle) - Construct a new LifecycleSupport object associated with the specified
Lifecycle component.
|
LifecycleSupport
public LifecycleSupport(Lifecycle lifecycle)
Construct a new LifecycleSupport object associated with the specified
Lifecycle component.
lifecycle
- The Lifecycle component that will be the source
of events that we fire
addLifecycleListener
public void addLifecycleListener(LifecycleListener listener)
Add a lifecycle event listener to this component.
listener
- The listener to add
findLifecycleListeners
public LifecycleListener[] findLifecycleListeners()
Get the lifecycle listeners associated with this lifecycle. If this
Lifecycle has no listeners registered, a zero-length array is returned.
fireLifecycleEvent
public void fireLifecycleEvent(String type,
Object data)
Notify all lifecycle event listeners that a particular event has
occurred for this Container. The default implementation performs
this notification synchronously using the calling thread.
type
- Event typedata
- Event data
removeLifecycleListener
public void removeLifecycleListener(LifecycleListener listener)
Remove a lifecycle event listener from this component.
listener
- The listener to remove
Copyright B) 2000-2003 Apache Software Foundation. All Rights Reserved.