public interface PropertyValue
A PropertyValue provides a mechanism whereby the currently configured value of a processor property can be obtained in different forms.
Modifier and Type | Method and Description |
---|---|
Boolean |
asBoolean() |
ControllerService |
asControllerService() |
<T extends ControllerService> |
asControllerService(Class<T> serviceType) |
Double |
asDataSize(DataUnit dataUnit) |
Double |
asDouble() |
Float |
asFloat() |
Integer |
asInteger() |
Long |
asLong() |
Long |
asTimePeriod(TimeUnit timeUnit) |
PropertyValue |
evaluateAttributeExpressions()
Replaces values in the Property Value using the NiFi Expression
Language; a PropertyValue with the new value is then returned, supporting
call chaining.
|
PropertyValue |
evaluateAttributeExpressions(AttributeValueDecorator decorator)
Replaces values in the Property Value using the NiFi Expression
Language.
|
PropertyValue |
evaluateAttributeExpressions(FlowFile flowFile)
Replaces values in the Property Value using the NiFi Expression
Language; a PropertyValue with the new value is then returned, supporting
call chaining.
|
PropertyValue |
evaluateAttributeExpressions(FlowFile flowFile,
AttributeValueDecorator decorator)
Replaces values in the Property Value using the NiFi Expression
Language.
|
PropertyValue |
evaluateAttributeExpressions(FlowFile flowFile,
Map<String,String> additionalAttributes)
Replaces values in the Property Value using the NiFi Expression
Language; a PropertyValue with the new value is then returned, supporting
call chaining.
|
PropertyValue |
evaluateAttributeExpressions(FlowFile flowFile,
Map<String,String> additionalAttributes,
AttributeValueDecorator decorator)
Replaces values in the Property Value using the NiFi Expression
Language; a PropertyValue with the new value is then returned, supporting
call chaining.
|
PropertyValue |
evaluateAttributeExpressions(Map<String,String> attributes)
Replaces values in the Property Value using the NiFi Expression Language;
a PropertyValue with the new value is then returned, supporting call chaining.
|
PropertyValue |
evaluateAttributeExpressions(Map<String,String> attributes,
AttributeValueDecorator decorator)
Replaces values in the Property Value using the NiFi Expression Language.
|
String |
getValue() |
boolean |
isSet() |
String getValue()
Integer asInteger()
null
if not setNumberFormatException
- if not able to parseLong asLong()
null
if not setNumberFormatException
- if not able to parseBoolean asBoolean()
null
if not setFloat asFloat()
null
if not setNumberFormatException
- if not able to parseDouble asDouble()
null
if not setNumberFormatException
- if not able to parseLong asTimePeriod(TimeUnit timeUnit)
timeUnit
- specifies the TimeUnit to convert the time duration intonull
Double asDataSize(DataUnit dataUnit)
dataUnit
- specifies the DataUnit to convert the data size intonull
ControllerService asControllerService()
this
, or null
if either the value is not set or
the value does not identify a ControllerService<T extends ControllerService> T asControllerService(Class<T> serviceType) throws IllegalArgumentException
T
- the generic type of the controller serviceserviceType
- the class of the Controller Servicethis
, or null
if either the value is not set or
the value does not identify a ControllerService. The object returned by
this method is explicitly cast to type specified, if the type specified
is valid. Otherwise, throws an IllegalArgumentExceptionIllegalArgumentException
- if the value of this
points
to a ControllerService but that service is not of type
serviceType
or if serviceType
references a
class that is not an interfaceboolean isSet()
true
if the user has configured a value, or if the
PropertyDescriptor
for the associated property has a default
value, false
otherwisePropertyValue evaluateAttributeExpressions() throws ProcessException
Replaces values in the Property Value using the NiFi Expression Language; a PropertyValue with the new value is then returned, supporting call chaining.
ProcessException
- if the Expression cannot be compiled or evaluating
the Expression against the given attributes causes an Exception to be thrownPropertyValue evaluateAttributeExpressions(Map<String,String> attributes) throws ProcessException
Replaces values in the Property Value using the NiFi Expression Language; a PropertyValue with the new value is then returned, supporting call chaining.
attributes
- a Map of attributes that the Expression can reference, in addition
to JVM System Properties and Environmental Properties.ProcessException
- if the Expression cannot be compiled or evaluating the Expression against
the given attributes causes an Exception to be thrownPropertyValue evaluateAttributeExpressions(Map<String,String> attributes, AttributeValueDecorator decorator) throws ProcessException
Replaces values in the Property Value using the NiFi Expression Language. The supplied decorator is then given a chance to decorate the value, and a PropertyValue with the new value is then returned, supporting call chaining.
attributes
- a Map of attributes that the Expression can reference, in addition
to JVM System Properties and Environmental Properties.decorator
- the decorator to use in order to update the values returned by the Expression LanguageProcessException
- if the Expression cannot be compiled or evaluating the Expression against
the given attributes causes an Exception to be thrownPropertyValue evaluateAttributeExpressions(FlowFile flowFile) throws ProcessException
Replaces values in the Property Value using the NiFi Expression Language; a PropertyValue with the new value is then returned, supporting call chaining.
flowFile
- to evaluate attributes ofProcessException
- if the Expression cannot be compiled or evaluating
the Expression against the given attributes causes an Exception to be thrownPropertyValue evaluateAttributeExpressions(FlowFile flowFile, Map<String,String> additionalAttributes) throws ProcessException
Replaces values in the Property Value using the NiFi Expression Language; a PropertyValue with the new value is then returned, supporting call chaining.
flowFile
- to evaluate attributes ofadditionalAttributes
- a Map of additional attributes that the Expression can reference. If entries in
this Map conflict with entries in the FlowFile's attributes, the entries in this Map are given a higher priority.ProcessException
- if the Expression cannot be compiled or evaluating
the Expression against the given attributes causes an Exception to be thrownPropertyValue evaluateAttributeExpressions(FlowFile flowFile, Map<String,String> additionalAttributes, AttributeValueDecorator decorator) throws ProcessException
Replaces values in the Property Value using the NiFi Expression Language; a PropertyValue with the new value is then returned, supporting call chaining.
flowFile
- to evaluate attributes ofadditionalAttributes
- a Map of additional attributes that the Expression can reference. If entries in
this Map conflict with entries in the FlowFile's attributes, the entries in this Map are given a higher priority.decorator
- the decorator to use in order to update the values returned by the Expression LanguageProcessException
- if the Expression cannot be compiled or evaluating
the Expression against the given attributes causes an Exception to be thrownPropertyValue evaluateAttributeExpressions(AttributeValueDecorator decorator) throws ProcessException
Replaces values in the Property Value using the NiFi Expression Language. The supplied decorator is then given a chance to decorate the value, and a PropertyValue with the new value is then returned, supporting call chaining.
decorator
- The supplied decorator is then given a chance to
decorate the valueProcessException
- if the Expression cannot be compiled or evaluating
the Expression against the given attributes causes an Exception to be thrownPropertyValue evaluateAttributeExpressions(FlowFile flowFile, AttributeValueDecorator decorator) throws ProcessException
Replaces values in the Property Value using the NiFi Expression Language. The supplied decorator is then given a chance to decorate the value, and a PropertyValue with the new value is then returned, supporting call chaining.
flowFile
- to evaluate expressions againstdecorator
- The supplied decorator is then given a chance to
decorate the valueProcessException
- if the Expression cannot be compiled or evaluating
the Expression against the given attributes causes an Exception to be thrownCopyright © 2017 Apache NiFi Project. All rights reserved.