Class ModifierEngine
java.lang.Object
de.fraunhofer.iese.mydata.common.MyDataEntity
de.fraunhofer.iese.mydata.policy.decision.ModifierEngine
- All Implemented Interfaces:
ParameterListProvider
A modifier engine describes a method that can be performed on event parameters. Despite an engine
name it contains a list of parameters required for the processing the engine.
- Author:
- Fraunhofer IESE
-
Constructor Summary
ConstructorsConstructorDescriptionModifierEngine(String name) Instantiates a new modifier engine.ModifierEngine(String name, ParameterList params) Instantiates a new modifier engine. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddParameter(Parameter<?> param) Adds a parameter.<T> voidaddParameter(String name, T value) Adds a parameter.voidRemoves all parameters.Parameter<?>getParameterForName(String name) Gets a parameter.<T> TgetParameterValue(String name, Class<T> clazz) Gets a parameter value.voidremoveParameter(String name) Adds a parameter.voidsetParameters(ParameterList params) Replaces all parameters with the parameters of the provided list.Methods inherited from class de.fraunhofer.iese.mydata.common.MyDataEntity
fromJson, getGson, getGson, toJson, toString, validate, validateAndNullCheckMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface de.fraunhofer.iese.mydata.policy.parameter.ParameterListProvider
getParameters
-
Constructor Details
-
ModifierEngine
Instantiates a new modifier engine.- Parameters:
name- the name of the parameter
-
ModifierEngine
Instantiates a new modifier engine.- Parameters:
name- the name of the parameterparams- the parameter values
-
-
Method Details
-
addParameter
Description copied from interface:ParameterListProviderAdds a parameter.- Specified by:
addParameterin interfaceParameterListProvider- Parameters:
param- the parameter to add
-
addParameter
Description copied from interface:ParameterListProviderAdds a parameter.- Specified by:
addParameterin interfaceParameterListProvider- Type Parameters:
T- the generic type- Parameters:
name- the name of the parametervalue- the value of the parameter
-
clearParameters
public void clearParameters()Description copied from interface:ParameterListProviderRemoves all parameters.- Specified by:
clearParametersin interfaceParameterListProvider
-
getParameterForName
Description copied from interface:ParameterListProviderGets a parameter.- Specified by:
getParameterForNamein interfaceParameterListProvider- Parameters:
name- the name of the parameter- Returns:
- the parameter with the given name, or null if it does not exist
-
getParameterValue
Description copied from interface:ParameterListProviderGets a parameter value.- Specified by:
getParameterValuein interfaceParameterListProvider- Type Parameters:
T- the generic type- Parameters:
name- the name of the parameterclazz- the value of the parameter- Returns:
- the value of the parameter, or null if it does not exist
-
removeParameter
Description copied from interface:ParameterListProviderAdds a parameter.- Specified by:
removeParameterin interfaceParameterListProvider- Parameters:
name- the name of the parameter to be deleted
-
setParameters
Description copied from interface:ParameterListProviderReplaces all parameters with the parameters of the provided list.- Specified by:
setParametersin interfaceParameterListProvider- Parameters:
params- list of parameters
-