You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@geode.apache.org by "Patrick Rhomberg (JIRA)" <ji...@apache.org> on 2018/02/22 23:34:00 UTC

[jira] [Created] (GEODE-4733) Replace ObjectUtils.defaultIfNull methods with ternary operator.

Patrick Rhomberg created GEODE-4733:
---------------------------------------

             Summary: Replace ObjectUtils.defaultIfNull methods with ternary operator.
                 Key: GEODE-4733
                 URL: https://issues.apache.org/jira/browse/GEODE-4733
             Project: Geode
          Issue Type: Sub-task
            Reporter: Patrick Rhomberg


{{defaultIfNull(T... values)}} is exclusively called with two input parameters, while the method name and signature makes it unclear that the second value is meant to be the default value if the first parameter is null.

This method can be cleanly replaced by a ternary {{v1 != null ? v1 : v2}}.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)