org.codehaus.plexus.lifecycle
Class AbstractLifecycleHandler

java.lang.Object
  extended byorg.codehaus.plexus.logging.AbstractLogEnabled
      extended byorg.codehaus.plexus.lifecycle.AbstractLifecycleHandler
All Implemented Interfaces:
LifecycleHandler, LogEnabled
Direct Known Subclasses:
DefaultLifecycleHandler, PlexusLifecycleHandler

public abstract class AbstractLifecycleHandler
extends AbstractLogEnabled
implements LifecycleHandler


Field Summary
private  java.util.List beginSegment
           
private  java.util.List endSegment
           
private  java.util.Map entities
           
private  java.lang.String id
           
private  java.lang.String name
           
private  java.util.List resumeSegment
           
private  java.util.List suspendSegment
           
 
Fields inherited from class org.codehaus.plexus.logging.AbstractLogEnabled
 
Fields inherited from interface org.codehaus.plexus.lifecycle.LifecycleHandler
COMPONENT_REPOSITORY, CONTEXT, LOGGER, PLEXUS_CONTAINER
 
Constructor Summary
AbstractLifecycleHandler()
           
 
Method Summary
 void addEntity(java.lang.String key, java.lang.Object entity)
           
 void end(java.lang.Object component, ComponentManager manager)
          End a component's lifecycle.
 java.util.List getBeginSegment()
           
 java.util.List getEndSegment()
           
 java.util.Map getEntities()
           
 java.lang.String getId()
           
 java.lang.String getName()
           
 java.util.List getResumeSegment()
           
 java.util.List getSuspendSegment()
           
 void resume(java.lang.Object component, ComponentManager manager)
           
private  boolean segmentIsEmpty(java.util.List segment)
           
 void start(java.lang.Object component, ComponentManager manager)
          Start a component's lifecycle.
 void suspend(java.lang.Object component, ComponentManager manager)
           
 
Methods inherited from class org.codehaus.plexus.logging.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.codehaus.plexus.lifecycle.LifecycleHandler
enableLogging, initialize
 

Field Detail

id

private java.lang.String id

name

private java.lang.String name

entities

private java.util.Map entities

beginSegment

private java.util.List beginSegment

suspendSegment

private java.util.List suspendSegment

resumeSegment

private java.util.List resumeSegment

endSegment

private java.util.List endSegment
Constructor Detail

AbstractLifecycleHandler

public AbstractLifecycleHandler()
Method Detail

getId

public java.lang.String getId()
Specified by:
getId in interface LifecycleHandler

getName

public java.lang.String getName()

getEntities

public java.util.Map getEntities()
Specified by:
getEntities in interface LifecycleHandler

addEntity

public void addEntity(java.lang.String key,
                      java.lang.Object entity)
Specified by:
addEntity in interface LifecycleHandler

getBeginSegment

public java.util.List getBeginSegment()

getSuspendSegment

public java.util.List getSuspendSegment()

getResumeSegment

public java.util.List getResumeSegment()

getEndSegment

public java.util.List getEndSegment()

start

public void start(java.lang.Object component,
                  ComponentManager manager)
           throws java.lang.Exception
Start a component's lifecycle.

Specified by:
start in interface LifecycleHandler
Parameters:
component -
Throws:
java.lang.Exception - If an error occurs while attempting to beginSegment the component's lifecycle.

suspend

public void suspend(java.lang.Object component,
                    ComponentManager manager)
             throws java.lang.Exception
Specified by:
suspend in interface LifecycleHandler
Throws:
java.lang.Exception

resume

public void resume(java.lang.Object component,
                   ComponentManager manager)
            throws java.lang.Exception
Specified by:
resume in interface LifecycleHandler
Throws:
java.lang.Exception

end

public void end(java.lang.Object component,
                ComponentManager manager)
         throws java.lang.Exception
End a component's lifecycle.

Specified by:
end in interface LifecycleHandler
Parameters:
component -
Throws:
java.lang.Exception - If an error occurs while attempting to endSegment the component's lifecycle.

segmentIsEmpty

private boolean segmentIsEmpty(java.util.List segment)