All Downloads are FREE. Search and download functionalities are using the official Maven repository.

jadex.bridge.ComponentTerminatedException Maven / Gradle / Ivy

Go to download

Jadex bridge is a base package for kernels and platforms, i.e., it is used by both and provides commonly used interfaces and classes for active components and their management.

There is a newer version: 4.0.267
Show newest version
package jadex.bridge;


/**
 *  Thrown when operations are invoked after an component has been terminated.
 */
public class ComponentTerminatedException	extends RuntimeException
{
	//-------- attributes --------
	
	/** The component identifier. */
	protected IComponentIdentifier cid;
	
	//-------- constructors --------
	
	/**
	 *  Empty constructor for deserialization.
	 */
	public ComponentTerminatedException()
	{
		super();
	}
	
	/**
	 *	Create an component termination exception.  
	 */
	public ComponentTerminatedException(IComponentIdentifier cid)
	{
		super(cid.getName());
		this.cid = cid;
	}

	/**
	 *	Create an component termination exception.  
	 */
	public ComponentTerminatedException(IComponentIdentifier cid, String message)
	{
		super(cid.getName()+": "+message);
		this.cid = cid;
	}

	//-------- methods --------
	
	/**
	 *  Get the component identifier.
	 *  @return The component identifier.
	 */
	public IComponentIdentifier getComponentIdentifier()
	{
		return cid;
	}
	
	/**
	 *  Get the component identifier.
	 */
	public void setComponentIdentifier(IComponentIdentifier cid)
	{
		this.cid	= cid;
	}
	
	/*public void printStackTrace()
	{
		Thread.dumpStack();
		super.printStackTrace();
	}*/
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy