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

jadex.rules.eca.ICondition Maven / Gradle / Ivy

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

import jadex.commons.Tuple2;
import jadex.commons.future.Future;
import jadex.commons.future.IFuture;

/**
 *  Interface for a condition part of a rule.
 */
public interface ICondition
{
	public static Tuple2 TRUE = new Tuple2(Boolean.TRUE, null);
	
	public static Tuple2 FALSE = new Tuple2(Boolean.FALSE, null);
	
	public static ICondition TRUE_CONDITION = new ICondition()
	{
		public IFuture> evaluate(IEvent event)
		{
			return new Future>(TRUE);
		}
	};
	
//	/**
//	 *  Evaluation the condition.
//	 *  @param event The event.
//	 *  @return True, if condition is met (plus additional user data).
//	 */
//	public Tuple2 evaluate(IEvent event);
	
	/**
	 *  Evaluation the condition.
	 *  @param event The event.
	 *  @return True, if condition is met (plus additional user data).
	 */
	public IFuture> evaluate(IEvent event);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy