You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Benedikt Ritter (JIRA)" <ji...@apache.org> on 2016/08/18 11:37:20 UTC

[jira] [Commented] (LANG-1259) JavaDoc for ArrayUtils.isNotEmpty() is slightly misleading

    [ https://issues.apache.org/jira/browse/LANG-1259?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15426299#comment-15426299 ] 

Benedikt Ritter commented on LANG-1259:
---------------------------------------

Hello [~centic],

your proposal sounds reasonable. I'm having trouble to apply your patch. It looks like it has not been created based on the lastest state of the code base. I'm getting:

{code}
$ git apply ArrayUtils.isNotEmpty.patch
ArrayUtils.isNotEmpty.patch:13: trailing whitespace.
     * <p>Checks if an array of Objects is not empty and not {@code null}.</p>
ArrayUtils.isNotEmpty.patch:18: trailing whitespace.
     * @return {@code true} if the array is not empty and not {@code null}
ArrayUtils.isNotEmpty.patch:27: trailing whitespace.
     * <p>Checks if an array of primitive longs is not empty and not {@code null}.</p>
ArrayUtils.isNotEmpty.patch:31: trailing whitespace.
     * @return {@code true} if the array is not empty and not {@code null}
ArrayUtils.isNotEmpty.patch:40: trailing whitespace.
     * <p>Checks if an array of primitive ints is not empty and not {@code null}.</p>
error: main/java/org/apache/commons/lang3/ArrayUtils.java: No such file or directory
{code}

Can you take a look?

> JavaDoc for ArrayUtils.isNotEmpty() is slightly misleading
> ----------------------------------------------------------
>
>                 Key: LANG-1259
>                 URL: https://issues.apache.org/jira/browse/LANG-1259
>             Project: Commons Lang
>          Issue Type: Improvement
>            Reporter: Dominik Stadler
>            Assignee: Benedikt Ritter
>            Priority: Minor
>              Labels: PatchAvailable
>         Attachments: ArrayUtils.isNotEmpty.patch
>
>
> JavaDoc states {{if the array is not empty or not null}}, however actually it is {{if the array is not empty and not null}}, i.e. "and" instead of "or". Looks like a small copy/paste error from "isEmpty()"
> Attached patch fixes all the instances.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)