Re: Gee Functional iterators



On Tue, Jul 13, 2010 at 10:39 PM, Maciej Piechotka
<uzytkownik2 gmail com> wrote:
>>
>> If we're working with external iterators, some collection methods
>> would be nice to have too:
>
> Sorry - I don't understand the above sentence.

I meant, methods that use the iterator to fill one or more
collections, rather than having the user do it via foreach. (I missed
addAll, that is indeed what I meant by collect(), though inside out.
partition() would still be nice.)

One other thing - what about indexed iterators? Perhaps a method

Iterator<Pair<int, G>> indexed(Iterator <G>) that converts, say, map
into map-with-index. (Even better if vala gets support for multivalued
iterators, though that seems like quite a huge change :))

martin


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]