A iterator with a generic method next()?

Reinier Zwitserloot reinier at zwitserloot.com
Wed Nov 11 18:06:53 PST 2009


Er, Iterator HAS a T next() method.

coin-dev is not a melting pot for random ill-thought out rough sketches.

--Reinier Zwitserloot



On Thu, Nov 12, 2009 at 3:02 AM, Paulo Levi <i30817 at gmail.com> wrote:

> Recently i'm thinking that a iterator with a
> <T> T next()  method is a good idea, for some uses. The interface is
> different from the normal iterator, so it can't be used for
> the for loop (or at least it would be fairly useless if so), but i'm
> thinking of using it as a proxy of ObjectInputStream + factories in
> case that the object in the file are not there (or the file doesn't
> exist), where the saved objects are of different types.
>
> Just tossing this idea into the melting pot.
>
>



More information about the coin-dev mailing list