You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by martin-tarjanyi <gi...@git.apache.org> on 2016/12/04 21:50:22 UTC
[GitHub] commons-lang pull request #221: Add IsAllEmpty and isAllBlank methods
GitHub user martin-tarjanyi opened a pull request:
https://github.com/apache/commons-lang/pull/221
Add IsAllEmpty and isAllBlank methods
* Fix javadoc
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/martin-tarjanyi/commons-lang All_empty_and_blank_methods
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/commons-lang/pull/221.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #221
----
commit 72ee6d222fe7ee96dd493c6e2d04e6c49eb78f5c
Author: Martin <tm...@gmail.com>
Date: 2016-12-04T21:13:20Z
Add isAllEmpty
commit 795dd2790310b886cd2f3a516e5835582d51b601
Author: Martin <tm...@gmail.com>
Date: 2016-12-04T21:22:20Z
Add isAllBlank
commit ee9b2b2a586fcc9fa7a521df859c439f384601f2
Author: Martin <tm...@gmail.com>
Date: 2016-12-04T21:25:27Z
Fix javadoc in isAnyNotBlank
----
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang issue #221: Add IsAllEmpty and isAllBlank methods
Posted by PascalSchumacher <gi...@git.apache.org>.
Github user PascalSchumacher commented on the issue:
https://github.com/apache/commons-lang/pull/221
>I vote strongly for is* method naming. That's the convention for Java methods of this type, even if it slightly upsets the English ear.
Then let's keep is* names.
>Other topic: what do you think of the handling of empty array or null as a single parameter? Is it right to return true in these cases?
I'm not sure what the behavior should be in these cases. @dmjones500 / anybody else: any opinions on this?
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang issue #221: Add IsAllEmpty and isAllBlank methods
Posted by martin-tarjanyi <gi...@git.apache.org>.
Github user martin-tarjanyi commented on the issue:
https://github.com/apache/commons-lang/pull/221
Hi @PascalSchumacher,
Is there any update on this matter? Should I change something?
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang issue #221: Add IsAllEmpty and isAllBlank methods
Posted by PascalSchumacher <gi...@git.apache.org>.
Github user PascalSchumacher commented on the issue:
https://github.com/apache/commons-lang/pull/221
@martin-tarjanyi Sorry for the delay. :( I finally send a mail to the mailing list:
https://mail-archives.apache.org/mod_mbox/commons-dev/201702.mbox/%3C13256228-1650-e98e-fe93-22801e530c88%40gmx.net%3E
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang issue #221: Add IsAllEmpty and isAllBlank methods
Posted by martin-tarjanyi <gi...@git.apache.org>.
Github user martin-tarjanyi commented on the issue:
https://github.com/apache/commons-lang/pull/221
The names you suggest express the use cases better, I agree.
The only thing I'm afraid of is that people might have a difficult time finding them since most of the blank/empty methods start with 'is'.
I'll change it, though.
Other topic: what do you think of the handling of empty array or null as a single parameter? Is it right to return true in these cases?
Can I use git rebase to add changes or brand new commits are the preferred way?
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang pull request #221: Add IsAllEmpty and isAllBlank methods
Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:
https://github.com/apache/commons-lang/pull/221
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang issue #221: Add IsAllEmpty and isAllBlank methods
Posted by coveralls <gi...@git.apache.org>.
Github user coveralls commented on the issue:
https://github.com/apache/commons-lang/pull/221
[![Coverage Status](https://coveralls.io/builds/9122523/badge)](https://coveralls.io/builds/9122523)
Changes Unknown when pulling **ee9b2b2a586fcc9fa7a521df859c439f384601f2 on martin-tarjanyi:All_empty_and_blank_methods** into ** on apache:master**.
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang issue #221: Add IsAllEmpty and isAllBlank methods
Posted by PascalSchumacher <gi...@git.apache.org>.
Github user PascalSchumacher commented on the issue:
https://github.com/apache/commons-lang/pull/221
Thanks for the pull request. :)
I guess we better class theses methods `areAllEmpty`/`areAllBlank`. What do you think?
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang issue #221: Add IsAllEmpty and isAllBlank methods
Posted by PascalSchumacher <gi...@git.apache.org>.
Github user PascalSchumacher commented on the issue:
https://github.com/apache/commons-lang/pull/221
I have created an jira issue for this: https://issues.apache.org/jira/browse/LANG-1293 and also asked for opinions on the empty/null array question there.
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang issue #221: Add IsAllEmpty and isAllBlank methods
Posted by PascalSchumacher <gi...@git.apache.org>.
Github user PascalSchumacher commented on the issue:
https://github.com/apache/commons-lang/pull/221
On further consideration, there are already methods with are "simply the inverse of another method": `isEmpty/isNotEmpty`, `isAnyEmpty/isNoneEmpty`, `containsAny/containsNone`. I will start a discussion on the mailing list.
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang issue #221: Add IsAllEmpty and isAllBlank methods
Posted by dmjones500 <gi...@git.apache.org>.
Github user dmjones500 commented on the issue:
https://github.com/apache/commons-lang/pull/221
I vote strongly for `is*` method naming. That's the convention for Java methods of this type, even if it slightly upsets the English ear.
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang issue #221: Add IsAllEmpty and isAllBlank methods
Posted by dmjones500 <gi...@git.apache.org>.
Github user dmjones500 commented on the issue:
https://github.com/apache/commons-lang/pull/221
I commented on the naming conventions without actually reviewing the change...
I don't think we should add methods that are simply the inverse of another method. It bloats the code base for no real gain.
I wouldn't be in favour of committing these new methods. The Javadoc fix is welcome, of course!
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] commons-lang issue #221: Add IsAllEmpty and isAllBlank methods
Posted by PascalSchumacher <gi...@git.apache.org>.
Github user PascalSchumacher commented on the issue:
https://github.com/apache/commons-lang/pull/221
If only one method is added it should be `isAll*` instead of `isAnyNot*`. Since the `isAnyNot*` are not released yet, they can be removed.
I personally would have no problem with adding both types of methods. Making client code more readable is imho enough to justify the addition.
---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---