[ 
https://issues.apache.org/jira/browse/COLLECTIONS-674?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Gary D. Gregory updated COLLECTIONS-674:
----------------------------------------
    Description: 
Add CollectionUtils removeRange and removeCount.

Original request:

Add a {{Collections.drain()}} method which removes the first N elements from 
the collection and returns them.  This method would have the side-effect of 
modifying the input collections (due to removal).

 
{code:java}
// Some suggestions
void Collections.drain(Collection<T> from, Collection<T> to, int count);
Collection<t> Collections.drain(Collection<t> from, int count);{code}

  was:
Add a {{Collections.drain()}} method which removes the first N elements from 
the collection and returns them.  This method would have the side-effect of 
modifying the input collections (due to removal).

 
{code:java}
// Some suggestions
void Collections.drain(Collection<T> from, Collection<T> to, int count);
Collection<t> Collections.drain(Collection<t> from, int count);{code}


> Add CollectionUtils removeRange, removeCount
> --------------------------------------------
>
>                 Key: COLLECTIONS-674
>                 URL: https://issues.apache.org/jira/browse/COLLECTIONS-674
>             Project: Commons Collections
>          Issue Type: Improvement
>          Components: Collection
>    Affects Versions: 4.1
>            Reporter: David Mollitor
>            Priority: Major
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> Add CollectionUtils removeRange and removeCount.
> Original request:
> Add a {{Collections.drain()}} method which removes the first N elements from 
> the collection and returns them.  This method would have the side-effect of 
> modifying the input collections (due to removal).
>  
> {code:java}
> // Some suggestions
> void Collections.drain(Collection<T> from, Collection<T> to, int count);
> Collection<t> Collections.drain(Collection<t> from, int count);{code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to