public class FunctionLib
extends java.lang.Object
Constructor and Description |
---|
FunctionLib(de.uka.ipd.sdq.probfunction.math.IRandomGenerator randomStream,
de.uka.ipd.sdq.probfunction.math.IPDFFactory factory)
Initialise the function library.
|
Modifier and Type | Method and Description |
---|---|
void |
addFunction(java.lang.String id,
IFunction f)
Add a function to this function library.
|
java.lang.Object |
evaluate(java.lang.String functionID,
java.util.ArrayList<java.lang.Object> parameterValues)
Evaluate the function with the given ID using the given parameters, e.g.
|
de.uka.ipd.sdq.probfunction.math.IRandomGenerator |
getRandomStream() |
public FunctionLib(de.uka.ipd.sdq.probfunction.math.IRandomGenerator randomStream, de.uka.ipd.sdq.probfunction.math.IPDFFactory factory)
public void addFunction(java.lang.String id, IFunction f)
getRandomStream()
.id
- Name of the function to add. It is the ID in the stoexf
- The function object used during evaluationpublic de.uka.ipd.sdq.probfunction.math.IRandomGenerator getRandomStream()
public java.lang.Object evaluate(java.lang.String functionID, java.util.ArrayList<java.lang.Object> parameterValues)
functionID
- ID of the function to evaluateparameterValues
- Parameter set to use in evaluation