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

jadex.bdi.benchmarks.Counter 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;


/**
 *  A thread safe counter to determine when all agents are running.  
 */
public class Counter
{
	//-------- attributes --------
	
	/** The counter. */
	protected int	cnt	= 0;
	
	//-------- constructors --------
	
	/**
	 *  Increment and return the counter value. 
	 */
	public synchronized int	increment()
	{
		return ++cnt;
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy