Github user JPercivall commented on a diff in the pull request:

    https://github.com/apache/nifi/pull/1333#discussion_r92842330
  
    --- Diff: nifi-docs/src/main/asciidoc/expression-language-guide.adoc ---
    @@ -963,6 +963,36 @@ Expressions will provide the following results:
        will return 0.
     
     
    +[.function]
    +=== ifElse
    +
    +*Description*: [.description]#Evaluates the first argument if the Subject 
evaluates to true, or the second argument
    +if the Subject evaluates to false.#
    +
    +*Subject Type*: [.subject]#Boolean#
    +
    +*Arguments*:
    +
    +   - [.argName]#_EvaluateIfTrue_# : [.argDesc]#The value to return if the 
Subject is true#
    +   - [.argName]#_EvaluateIfFalse_# : [.argDesc]#The value to return if the 
Subject is false#
    +
    +*Return Type*: [.returnType]#String#
    +
    +*Examples*: If the "filename" attribute has the value "a brand new 
filename.txt", the "nullFilename" attribute has
    +the value null, and the "bool" attribute has the value "true", then the 
following expressions will provide
    +the following results:
    +
    +
    +
    +.ifElse Examples
    +|===================================================================
    +| Expression | Value
    +| `${filename:ifElse('found', 'not_found')}` | `found`
    --- End diff --
    
    Actually this will not return 'found' because when the String is converted 
to a boolean it is only true if it is equalsIgnoreCase to "true".


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to