equals
Description: The equals
function is
very widely used and determines if its subject is equal to another String value. Note that
the equals
function performs a direct comparison of two String values.
Take care not to confuse this function with the matches
function, which evaluates its subject against a Regular Expression.
Subject Type: Any
Arguments:
value : The value to compare the Subject to. Must be same type as the Subject.
Return Type: Boolean
Examples: We can check if the filename of a FlowFile is
"hello.txt" by using the expression
${filename:equals('hello.txt')}
, or we could check if the
value of the attribute hello
is equal to the value of the
filename
attribute: ${hello:equals( ${filename}
)}
.