Interface InputDataContext
- All Superinterfaces:
PluginDataContainer,UserAttributeContainer
- All Known Subinterfaces:
DataContext,ParameterDataContext,SerialisableDataContext
- All Known Implementing Classes:
SettableDataContext
This interface provides read access to all parameters of an application or a node. Access is
based on the name of a parameter. It may be retrieved whether a parameter is null and the
corresponding values.
-
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns whether the value of the designated parameter is NULL which means the data element has not been written or has been consumed yet or has been explicitly set to NULL by a previous application.booleanretrieveBooleanParameterValue(String parameterName) Reads from an input parameter.retrieveDateParameterValue(String parameterName) Reads from an input parameter.doubleretrieveFloatParameterValue(String parameterName) Reads from an input parameter.longretrieveIntegerParameterValue(String parameterName) Reads from an input parameter.retrieveStringParameterValue(String parameterName) Reads from an input parameter.retrieveUDTParameterValue(String parameterName) Reads from an input parameter.retrieveURIParameterValue(String parameterName) Reads from an input parameter.Methods inherited from interface de.aristaflow.adept2.model.common.PluginDataContainer
getPluginData, getPluginDatas, getSupportedPluginsMethods inherited from interface de.aristaflow.adept2.model.common.UserAttributeContainer
getUserAttributes, getUserAttributeValue, removeUserAttributeValue, setUserAttributeValue
-
Method Details
-
isNull
Returns whether the value of the designated parameter is NULL which means the data element has not been written or has been consumed yet or has been explicitly set to NULL by a previous application. This method has to be called before retrieving a value.- Parameters:
parameterName- The name of the parameter to check on NULL.- Returns:
trueif the value of the designated parameter is NULL and therefore has not been written or has been consumed yet.- Throws:
NoSuchParameterException- If the parameter of the designated name does not exist, aNoSuchParameterExceptionwill be thrown.
-
retrieveIntegerParameterValue
long retrieveIntegerParameterValue(String parameterName) throws NoSuchParameterException, InvalidDataTypeException Reads from an input parameter. The associated value must be of type long.
Callers should first check whether the value is NULL by callingisNull(String). Otherwise in case of NULL anIllegalStateExceptionwill be thrown.- Parameters:
parameterName- the name of the input parameter to be read- Returns:
- The value for the designated input parameter.
- Throws:
NoSuchParameterException- If the parameter of the designated name does not exist, aNoSuchParameterExceptionwill be thrown.InvalidDataTypeException- If the designated parameter is not of type INTEGER, anInvalidDataTypeExceptionwill be raised.IllegalStateException- If the value of the designated parameter is NULL, anIllegalStateExceptionwill be thrown.
-
retrieveFloatParameterValue
double retrieveFloatParameterValue(String parameterName) throws NoSuchParameterException, InvalidDataTypeException Reads from an input parameter. The associated value must be of type double.
Callers should first check whether the value is NULL by callingisNull(String). Otherwise in case of NULL anIllegalStateExceptionwill be thrown.- Parameters:
parameterName- the name of the input parameter to be read- Returns:
- The value for the designated input parameter.
- Throws:
NoSuchParameterException- If the parameter of the designated name does not exist, aNoSuchParameterExceptionwill be thrown.InvalidDataTypeException- If the designated parameter is not of type FLOAT, anInvalidDataTypeExceptionwill be raised.IllegalStateException- If the value of the designated parameter is NULL, anIllegalStateExceptionwill be thrown.
-
retrieveBooleanParameterValue
boolean retrieveBooleanParameterValue(String parameterName) throws NoSuchParameterException, InvalidDataTypeException Reads from an input parameter. The associated value must be of type boolean.
Callers should first check whether the value is NULL by callingisNull(String). Otherwise in case of NULL anIllegalStateExceptionwill be thrown.- Parameters:
parameterName- the name of the input parameter to be read- Returns:
- The value for the designated input parameter.
- Throws:
NoSuchParameterException- If the parameter of the designated name does not exist, aNoSuchParameterExceptionwill be thrown.InvalidDataTypeException- If the designated parameter is not of type BOOLEAN, anInvalidDataTypeExceptionwill be raised.IllegalStateException- If the value of the designated parameter is NULL, anIllegalStateExceptionwill be thrown.
-
retrieveStringParameterValue
String retrieveStringParameterValue(String parameterName) throws NoSuchParameterException, InvalidDataTypeException Reads from an input parameter. The associated value must be of type String.
Callers should first check whether the value is NULL by callingisNull(String). Otherwise in case of NULL anIllegalStateExceptionwill be thrown.- Parameters:
parameterName- the name of the input parameter to be read- Returns:
- The value for the designated input parameter.
- Throws:
NoSuchParameterException- If the parameter of the designated name does not exist, aNoSuchParameterExceptionwill be thrown.InvalidDataTypeException- If the designated parameter is not of type STRING, anInvalidDataTypeExceptionwill be raised.IllegalStateException- If the value of the designated parameter is NULL, anIllegalStateExceptionwill be thrown.
-
retrieveDateParameterValue
Date retrieveDateParameterValue(String parameterName) throws NoSuchParameterException, InvalidDataTypeException Reads from an input parameter. The associated value must be of typejava.util.Date.
Callers should first check whether the value is NULL by callingisNull(String). Otherwise in case of NULL anIllegalStateExceptionwill be thrown.- Parameters:
parameterName- the name of the input parameter to be read- Returns:
- The value for the designated input parameter.
- Throws:
NoSuchParameterException- If the parameter of the designated name does not exist, aNoSuchParameterExceptionwill be thrown.InvalidDataTypeException- If the designated parameter is not of type DATE, anInvalidDataTypeExceptionwill be raised.IllegalStateException- If the value of the designated parameter is NULL, anIllegalStateExceptionwill be thrown.
-
retrieveURIParameterValue
URI retrieveURIParameterValue(String parameterName) throws NoSuchParameterException, InvalidDataTypeException Reads from an input parameter. The associated value must be of type URI.
Callers should first check whether the value is NULL by callingisNull(String). Otherwise in case of NULL anIllegalStateExceptionwill be thrown.- Parameters:
parameterName- the name of the input parameter to be read- Returns:
- The value for the designated input parameter.
- Throws:
InvalidDataTypeException- If the designated parameter is not of type URI, anInvalidDataTypeExceptionwill be raised.NoSuchParameterException- If the parameter of the designated name does not exist, aNoSuchParameterExceptionwill be thrown.IllegalStateException- If the value of the designated parameter is NULL, anIllegalStateExceptionwill be thrown.
-
retrieveUDTParameterValue
UDTValue retrieveUDTParameterValue(String parameterName) throws NoSuchParameterException, InvalidDataTypeException Reads from an input parameter. The associated value must be of an user-defined type.
Callers should first check whether the value is NULL by callingisNull(String). Otherwise in case of NULL anIllegalStateExceptionwill be thrown.- Parameters:
parameterName- the name of the input parameter to be read- Returns:
- The value for the designated input parameter. The UDTValue will be coupled
to this
InputDataContext, so do not close it; clone it if required longer than thisInputDataContext. - Throws:
InvalidDataTypeException- If the designated parameter is not of type UDT, anInvalidDataTypeExceptionwill be raised.NoSuchParameterException- If the parameter of the designated name does not exist, aNoSuchParameterExceptionwill be thrown.IllegalStateException- If the value of the designated parameter is NULL, anIllegalStateExceptionwill be thrown.
-