Package de.fraunhofer.iese.mydata.policy
Class PipRequest
java.lang.Object
de.fraunhofer.iese.mydata.common.MyDataEntity
de.fraunhofer.iese.mydata.policy.PipRequest
- All Implemented Interfaces:
ParameterListProvider
A request that instructs the PIP.
- Author:
- Fraunhofer IESE
-
Constructor Summary
ConstructorDescriptionPipRequest
(InfoId infoId, Parameter<?>... params) Instantiates a new pip request.PipRequest
(InfoId infoId, ParameterList params) Instantiates a new pip request. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addParameter
(Parameter<?> param) Adds a parameter.<R> void
addParameter
(String name, R value) Adds a parameter.void
Removes all parameters.boolean
Parameter<?>
getParameterForName
(String name) Gets a parameter.Gets the list of all parameters.<R> R
getParameterValue
(String name, Class<R> clazz) Gets a parameter value.int
hashCode()
void
removeParameter
(String name) Adds a parameter.void
setParameters
(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, validateAndNullCheck
-
Constructor Details
-
PipRequest
Instantiates a new pip request.- Parameters:
infoId
- the id of the method to be executedparams
- parameters used for evaluation
-
PipRequest
Instantiates a new pip request.- Parameters:
infoId
- the id of the method to be executedparams
- parameters used for evaluation
-
-
Method Details
-
addParameter
Description copied from interface:ParameterListProvider
Adds a parameter.- Specified by:
addParameter
in interfaceParameterListProvider
- Parameters:
param
- the parameter to add
-
addParameter
Description copied from interface:ParameterListProvider
Adds a parameter.- Specified by:
addParameter
in interfaceParameterListProvider
- Type Parameters:
R
- the generic type- Parameters:
name
- the name of the parametervalue
- the value of the parameter
-
clearParameters
public void clearParameters()Description copied from interface:ParameterListProvider
Removes all parameters.- Specified by:
clearParameters
in interfaceParameterListProvider
-
equals
-
hashCode
public int hashCode() -
getParameterForName
Description copied from interface:ParameterListProvider
Gets a parameter.- Specified by:
getParameterForName
in interfaceParameterListProvider
- Parameters:
name
- the name of the parameter- Returns:
- the parameter with the given name, or null if it does not exist
-
getParameters
Description copied from interface:ParameterListProvider
Gets the list of all parameters.- Specified by:
getParameters
in interfaceParameterListProvider
- Returns:
- the list of all parameters
-
setParameters
Description copied from interface:ParameterListProvider
Replaces all parameters with the parameters of the provided list.- Specified by:
setParameters
in interfaceParameterListProvider
- Parameters:
params
- list of parameters
-
getParameterValue
Description copied from interface:ParameterListProvider
Gets a parameter value.- Specified by:
getParameterValue
in interfaceParameterListProvider
- Type Parameters:
R
- 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:ParameterListProvider
Adds a parameter.- Specified by:
removeParameter
in interfaceParameterListProvider
- Parameters:
name
- the name of the parameter to be deleted
-