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 2014/02/01 13:40:09 UTC
[jira] [Comment Edited] (LANG-922) Add isOneTrue(booleans...) to
BooleanUtils to preserve old behavior of BooleanUtils.xor(booleans...)
[ https://issues.apache.org/jira/browse/LANG-922?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13888558#comment-13888558 ]
Benedikt Ritter edited comment on LANG-922 at 2/1/14 12:39 PM:
---------------------------------------------------------------
bq. I'd like to get away from static util methods that take 4 parameters
I've created LANG-964 to track the creation of fluent APIs, since this has to wait until 4.0.
was (Author: britter):
bq. I'd like to get away from static util methods that take 4 parameters
I've created LANG-964 to track the creating of fluent APIs, since this has to wait until 4.0.
> Add isOneTrue(booleans...) to BooleanUtils to preserve old behavior of BooleanUtils.xor(booleans...)
> ----------------------------------------------------------------------------------------------------
>
> Key: LANG-922
> URL: https://issues.apache.org/jira/browse/LANG-922
> Project: Commons Lang
> Issue Type: Task
> Components: lang.*
> Reporter: Benedikt Ritter
> Fix For: Discussion
>
>
> The old implementation (prior to r1532476) of BooleanUtils.xor(boolean...) checked if the provided array contained exactly one boolean with value true. This was changed because it is not the correct behavior for an XOR operation. To preserve the behavior we should add BooleanUtils.isOneTrue(boolean...) and BooleanUtils.isOneTrue(Boolean...) (and possibly the equivalents for isOneFalse).
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)