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

jadex.bdi.benchmarks.RequestSenderPlan Maven / Gradle / Ivy

Go to download

The Jadex BDI applications package contain several example applications, benchmarks and testcases using BDI agents.

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

import jadex.bdi.runtime.IGoal;
import jadex.bdi.runtime.Plan;
import jadex.bridge.IComponentManagementService;
import jadex.bridge.IComponentIdentifier;
import jadex.commons.service.SServiceProvider;

/**
 *	Handle requests and generate reply value.
 */
public class RequestSenderPlan extends Plan
{
	public void body()
	{
		int max	= ((Integer)getBeliefbase().getBelief("max").getFact()).intValue();
		IComponentIdentifier	receiver	= (IComponentIdentifier) getBeliefbase().getBelief("receiver").getFact();
		long	time	= System.currentTimeMillis();
		long	lasttime	= System.currentTimeMillis();

		for(int i=0; i




© 2015 - 2024 Weber Informatics LLC | Privacy Policy