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

jadex.bdi.cmsagent.CMSResumeComponentPlan Maven / Gradle / Ivy

Go to download

The Jadex applib BDI package contain ready to use functionalities for BDI agents mostly in form of modules called capabilities.

There is a newer version: 2.4
Show newest version
package jadex.bdi.cmsagent;

import jadex.bdi.runtime.IGoal;
import jadex.bdi.runtime.Plan;
import jadex.bridge.fipa.CMSResumeComponent;
import jadex.bridge.fipa.Done;

/**
 *  Resume an component.
 */
public class CMSResumeComponentPlan extends Plan
{
	/**
	 * The body method is called on the
	 * instatiated plan instance from the scheduler.
	 */
	public void body()
	{
		CMSResumeComponent ra = (CMSResumeComponent)getParameter("action").getValue();

		IGoal rag = createGoal("cms_suspend_component");
		rag.getParameter("componentidentifier").setValue(ra.getComponentIdentifier());
		dispatchSubgoalAndWait(rag);

		getParameter("result").setValue(new Done(ra));
	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy