org.apache.geronimo.kernel.config
Class LifecycleResults

java.lang.Object
  extended by org.apache.geronimo.kernel.config.LifecycleResults
All Implemented Interfaces:
Serializable

public class LifecycleResults
extends Object
implements Serializable

This class contains the results of a lifecycle operation on the configuation manager.

See Also:
Serialized Form

Constructor Summary
LifecycleResults()
           
 
Method Summary
 void addFailed(Artifact configurationId, Throwable cause)
          Adds a configuration and associated causal exception to this result.
 void addLoaded(Artifact configurationId)
          Adds a configuration the set of loaded configurations.
 void addStarted(Artifact configurationId)
          Adds a configuration the set of started configurations.
 void addStopped(Artifact configurationId)
          Adds a configuration the set of stopped configurations.
 void addUnloaded(Artifact configurationId)
          Adds a configuration the set of unloaded configurations.
 Map getFailed()
          Gets the configuration identifiers (Artifact) of the configurations that failed the operation and threw an exception.
 Throwable getFailedCause(Artifact configurationId)
          Gets the exception that caused the operation on the specified configuration to fail.
 Set getLoaded()
          Gets the configuration identifiers (Artifact) of the configurations loaded.
 Set getStarted()
          Gets the configuration identifiers (Artifact) of the configurations started.
 Set getStopped()
          Gets the configuration identifiers (Artifact) of the configurations stopped.
 Set getUnloaded()
          Gets the configuration identifiers (Artifact) of the configurations unloaded.
 void setFailed(Map failed)
          Clears the existing failed map and add alls the specified configurations to the map
 void setLoaded(Set loaded)
          Clears the existing loaded set and add alls the specified configurations to the set
 void setStarted(Set started)
          Clears the existing started set and add alls the specified configurations to the set
 void setStopped(Set stopped)
          Clears the existing stopped set and add alls the specified configurations to the set
 void setUnloaded(Set unloaded)
          Clears the existing unloaded set and add alls the specified configurations to the set
 boolean wasFailed(Artifact configurationId)
          Was the specified configuration failed the operation and threw an exception.
 boolean wasLoaded(Artifact configurationId)
          Checks whether the specified configuration was loaded.
 boolean wasStarted(Artifact configurationId)
          Checks whether the specified configuration was started.
 boolean wasStopped(Artifact configurationId)
          Checks whether the specified configuration was stopped.
 boolean wasUnloaded(Artifact configurationId)
          Checks whether the specified configuration was unloaded.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LifecycleResults

public LifecycleResults()
Method Detail

wasLoaded

public boolean wasLoaded(Artifact configurationId)
Checks whether the specified configuration was loaded.

Parameters:
configurationId - the configuration identifier, which must be fully resolved (isResolved() == true)
Returns:
true if the specified configuration was loaded during the lifecycle operation

getLoaded

public Set getLoaded()
Gets the configuration identifiers (Artifact) of the configurations loaded.

Returns:
the configuration identifiers (Artifact)

addLoaded

public void addLoaded(Artifact configurationId)
Adds a configuration the set of loaded configurations.

Parameters:
configurationId - the configuration identifiers (Artifact)

setLoaded

public void setLoaded(Set loaded)
Clears the existing loaded set and add alls the specified configurations to the set

Parameters:
loaded - the configuration identifiers (Artifact)

wasUnloaded

public boolean wasUnloaded(Artifact configurationId)
Checks whether the specified configuration was unloaded.

Parameters:
configurationId - the configuration identifier, which must be fully resolved (isResolved() == true)
Returns:
true if the specified configuration was unloaded during the lifecycle operation

getUnloaded

public Set getUnloaded()
Gets the configuration identifiers (Artifact) of the configurations unloaded.

Returns:
the configuration identifiers (Artifact)

addUnloaded

public void addUnloaded(Artifact configurationId)
Adds a configuration the set of unloaded configurations.

Parameters:
configurationId - the configuration identifiers (Artifact)

setUnloaded

public void setUnloaded(Set unloaded)
Clears the existing unloaded set and add alls the specified configurations to the set

Parameters:
unloaded - the configuration identifiers (Artifact)

wasStarted

public boolean wasStarted(Artifact configurationId)
Checks whether the specified configuration was started.

Parameters:
configurationId - the configuration identifier, which must be fully resolved (isResolved() == true)
Returns:
true if the specified configuration was started during the lifecycle operation

getStarted

public Set getStarted()
Gets the configuration identifiers (Artifact) of the configurations started.

Returns:
the configuration identifiers (Artifact)

addStarted

public void addStarted(Artifact configurationId)
Adds a configuration the set of started configurations.

Parameters:
configurationId - the configuration identifiers (Artifact)

setStarted

public void setStarted(Set started)
Clears the existing started set and add alls the specified configurations to the set

Parameters:
started - the configuration identifiers (Artifact)

wasStopped

public boolean wasStopped(Artifact configurationId)
Checks whether the specified configuration was stopped.

Parameters:
configurationId - the configuration identifier, which must be fully resolved (isResolved() == true)
Returns:
true if the specified configuration was stopped during the lifecycle operation

getStopped

public Set getStopped()
Gets the configuration identifiers (Artifact) of the configurations stopped.

Returns:
the configuration identifiers (Artifact)

addStopped

public void addStopped(Artifact configurationId)
Adds a configuration the set of stopped configurations.

Parameters:
configurationId - the configuration identifiers (Artifact)

setStopped

public void setStopped(Set stopped)
Clears the existing stopped set and add alls the specified configurations to the set

Parameters:
stopped - the configuration identifiers (Artifact)

wasFailed

public boolean wasFailed(Artifact configurationId)
Was the specified configuration failed the operation and threw an exception.

Parameters:
configurationId - the configuration identifier. May be a partial ID, in which case will check whether any matching conifguration failed.
Returns:
true if the specified (or any matching) configuration failed the operation and threw an exception during the lifecycle operation

getFailedCause

public Throwable getFailedCause(Artifact configurationId)
Gets the exception that caused the operation on the specified configuration to fail.

Returns:
the configuration identifiers (Artifact)

getFailed

public Map getFailed()
Gets the configuration identifiers (Artifact) of the configurations that failed the operation and threw an exception.

Returns:
the configuration identifiers (Artifact)

addFailed

public void addFailed(Artifact configurationId,
                      Throwable cause)
Adds a configuration and associated causal exception to this result.

Parameters:
configurationId - the configuration identifiers (Artifact)
cause - the exception that caused the operation on the specified configuration to fail

setFailed

public void setFailed(Map failed)
Clears the existing failed map and add alls the specified configurations to the map

Parameters:
failed - a map from configuration identifier (Artifact) to causal exception


Copyright © 2003-2007 Apache Software Foundation. All Rights Reserved.