You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Jean-Noel Rouvignac (JIRA)" <ji...@apache.org> on 2010/08/27 17:37:53 UTC
[jira] Created: (COLLECTIONS-362) Add CollectionUtils.filter()
should return a boolean indicating whether the Collection was modified as a
result of the call.
Add CollectionUtils.filter() should return a boolean indicating whether the Collection was modified as a result of the call.
----------------------------------------------------------------------------------------------------------------------------
Key: COLLECTIONS-362
URL: https://issues.apache.org/jira/browse/COLLECTIONS-362
Project: Commons Collections
Issue Type: Wish
Components: Collection
Affects Versions: 3.2
Reporter: Jean-Noel Rouvignac
Priority: Minor
Here is what I mean:
- test 1:
List l = new ArrayList();
l.add("test");
assertTrue( CollectionUtils.filter(l, FalsePredicate.getInstance()) );
assertTrue(l.isEmpty());
- test 2:
List l = new ArrayList();
l.add("test");
assertFalse( CollectionUtils.filter(l, TruePredicate.getInstance()) );
assertEquals(1, l.size());
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (COLLECTIONS-362) Add CollectionUtils.filter()
should return a boolean indicating whether the Collection was modified as a
result of the call.
Posted by "Jean-Noel Rouvignac (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COLLECTIONS-362?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jean-Noel Rouvignac updated COLLECTIONS-362:
--------------------------------------------
Description:
Here is what I mean:
- test 1:
List l = new ArrayList();
l.add("test");
assertTrue( CollectionUtils.filter(l, FalsePredicate.getInstance()) );
assertTrue(l.isEmpty());
- test 2:
List l = new ArrayList();
l.add("test");
assertFalse( CollectionUtils.filter(l, TruePredicate.getInstance()) );
assertEquals(1, l.size());
was:
Here is what I mean:
- test 1:
List l = new ArrayList();
l.add("test");
assertTrue( CollectionUtils.filter(l, FalsePredicate.getInstance()) );
assertTrue(l.isEmpty());
- test 2:
List l = new ArrayList();
l.add("test");
assertFalse( CollectionUtils.filter(l, TruePredicate.getInstance()) );
assertEquals(1, l.size());
> Add CollectionUtils.filter() should return a boolean indicating whether the Collection was modified as a result of the call.
> ----------------------------------------------------------------------------------------------------------------------------
>
> Key: COLLECTIONS-362
> URL: https://issues.apache.org/jira/browse/COLLECTIONS-362
> Project: Commons Collections
> Issue Type: Wish
> Components: Collection
> Affects Versions: 3.2
> Reporter: Jean-Noel Rouvignac
> Priority: Minor
>
> Here is what I mean:
> - test 1:
> List l = new ArrayList();
> l.add("test");
> assertTrue( CollectionUtils.filter(l, FalsePredicate.getInstance()) );
> assertTrue(l.isEmpty());
> - test 2:
> List l = new ArrayList();
> l.add("test");
> assertFalse( CollectionUtils.filter(l, TruePredicate.getInstance()) );
> assertEquals(1, l.size());
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (COLLECTIONS-362) CollectionUtils.filter() should
return a boolean indicating whether the Collection was modified as a result
of the call.
Posted by "Jean-Noel Rouvignac (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COLLECTIONS-362?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jean-Noel Rouvignac updated COLLECTIONS-362:
--------------------------------------------
Summary: CollectionUtils.filter() should return a boolean indicating whether the Collection was modified as a result of the call. (was: Add CollectionUtils.filter() should return a boolean indicating whether the Collection was modified as a result of the call.)
> CollectionUtils.filter() should return a boolean indicating whether the Collection was modified as a result of the call.
> ------------------------------------------------------------------------------------------------------------------------
>
> Key: COLLECTIONS-362
> URL: https://issues.apache.org/jira/browse/COLLECTIONS-362
> Project: Commons Collections
> Issue Type: Wish
> Components: Collection
> Affects Versions: 3.2
> Reporter: Jean-Noel Rouvignac
> Priority: Minor
>
> Here is what I mean:
> - test 1:
> List l = new ArrayList();
> l.add("test");
> assertTrue( CollectionUtils.filter(l, FalsePredicate.getInstance()) );
> assertTrue(l.isEmpty());
> - test 2:
> List l = new ArrayList();
> l.add("test");
> assertFalse( CollectionUtils.filter(l, TruePredicate.getInstance()) );
> assertEquals(1, l.size());
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (COLLECTIONS-362) CollectionUtils.filter() should
return a boolean indicating whether the Collection was modified as a result
of the call.
Posted by "Jean-Noel Rouvignac (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COLLECTIONS-362?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jean-Noel Rouvignac updated COLLECTIONS-362:
--------------------------------------------
Attachment: COLLECTIONS-362.patch
Here are the updated class and tests.
I think this is an API change, so it won't happen until commons collections 4?
> CollectionUtils.filter() should return a boolean indicating whether the Collection was modified as a result of the call.
> ------------------------------------------------------------------------------------------------------------------------
>
> Key: COLLECTIONS-362
> URL: https://issues.apache.org/jira/browse/COLLECTIONS-362
> Project: Commons Collections
> Issue Type: Wish
> Components: Collection
> Affects Versions: 3.2
> Reporter: Jean-Noel Rouvignac
> Priority: Minor
> Attachments: COLLECTIONS-362.patch
>
>
> Here is what I mean:
> - test 1:
> List l = new ArrayList();
> l.add("test");
> assertTrue( CollectionUtils.filter(l, FalsePredicate.getInstance()) );
> assertTrue(l.isEmpty());
> - test 2:
> List l = new ArrayList();
> l.add("test");
> assertFalse( CollectionUtils.filter(l, TruePredicate.getInstance()) );
> assertEquals(1, l.size());
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.