commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Harrington, James MAJ" <>
Subject Re: [io] File content iterator
Date Thu, 05 Jan 2006 09:31:44 GMT


That design sound perfectly reasonable to me.  


I'm thinking you would want to both close the resources used by the
iterator when it has served up the list line in the file AND allow the
resources to be explicitly closed so that a file could be partially
processed.  I would also add the ability to explicitly close the
iterator by introducing an appropriately named interface that the
returned iterator would also implement.  This would allow users that
don't want to explicitly close the iterator to simply use an instance of
java.util.Iterator and only require users who want to explicitly close
to cast to the introduced interface.


  Jim Harrington

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message