← Back to team overview

ooc-dev team mailing list archive

Re: Back/front methods for Iterable (and reverse iterators)

 

Bart makes a good point that not all Iterables will have an ordered
structure (ex: socket input/output streams).
I think it would make more sense having front() and back() methods in List
that returns Iterators that either traverse
the list head to tail or vice versa.

Josh

On Fri, May 28, 2010 at 9:33 AM, Amos Wenger <amoswenger@xxxxxxxxx> wrote:

> So what then? iterator~back() ?
>
>
> On Fri, May 28, 2010 at 2:53 PM, Bart van der Werf <bluelive@xxxxxxxxx>wrote:
>
>> I'm not sure.
>>
>> Alot of iterables have no order, so if front/back is the default way to
>> get an iterator it would make little sense.
>>
>
>
> _______________________________________________
> Mailing list: https://launchpad.net/~ooc-dev
> Post to     : ooc-dev@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~ooc-dev
> More help   : https://help.launchpad.net/ListHelp
>
>

Follow ups

References