jadex.micro.testcases.nfproperties.FakeReliabilityProperty Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jadex-applications-micro Show documentation
Show all versions of jadex-applications-micro Show documentation
The Jadex micro applications package contains several example applications, benchmarks and testcases using micro agents.
package jadex.micro.testcases.nfproperties;
import jadex.bridge.IInternalAccess;
import jadex.bridge.nonfunctional.NFPropertyMetaInfo;
import jadex.bridge.nonfunctional.SimpleValueNFProperty;
/**
* Property simulating a random service reliability.
*
*/
public class FakeReliabilityProperty extends SimpleValueNFProperty
{
/**
* Creates the property.
*/
public FakeReliabilityProperty(IInternalAccess comp)
{
super(comp, new NFPropertyMetaInfo("fakereliability", Double.class, Void.class, true, 10000, true, null));
}
/**
* Measure the value.
*/
public Double measureValue()
{
return Math.random() * 100.0;
}
}