nifi-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Uwe@Moosheimer.com" <...@Moosheimer.com>
Subject Question on isExpressionLanguagePresent
Date Sun, 03 Sep 2017 15:20:18 GMT
Dear Experts,

the following code throws a NPE: 

    /PropertyValue property = context.getProperty(SOME_PROPERTY);//
    //if (property.isExpressionLanguagePresent()) {/

when the property is not set (NULL).

So I have to write

    /PropertyValue property = context.getProperty(SOME_PROPERTY);//
    //if (property.isSet() && property.isExpressionLanguagePresent()) {
    /

Wouldn't it be great if the method isExpressionLanguagePreset() would
check for NULL and then return false?

Best Regards,
Uwe



Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message