Add iterate method to CsvToBean
Brought to you by:
aruckerjones,
sconway
Currently, CsvToBean has only a method that reads all lines of csv and returns a list.
This patch add a new method that takes same parameters than parse, but returns an iterator.
This method allows to use CsvToBean on large file without consume too many memory.
Hi I'm also in need of the iterator function, is there any chance this patch will ever make it into the next version? CsvToBean works great, but when we have very large files, it would be much better if we could iterate line by line rather than throwing everything into a list.
I will look at your patch later this week. This part of the year is hectic
with work/kids/school/scouts so I cannot give an ETA on 3.5 openCSV.
Plus I am getting murdered with the CSVReader isClosed issue: it is either
failing for people who use nio libraries or it is failing for people using
the standard stream reader - I cannot find a solution that will work for
both. That has the highest priority right now.
On Mon, Jul 27, 2015 at 8:14 AM, george gchristman@users.sf.net wrote:
--
Scott Conway
scott.conway@gmail.com
http://www.conwayfamily.name
Related
Patches:
#47I'm currently using my own implementation of CsvToBean with the patch and
it appears to work flawlessly. It should be a simple 5min patch for you.
Thank you so much for all your hard work.
On Jul 27, 2015 12:44 PM, "Scott Conway" sconway@users.sf.net wrote:
Related
Patches:
#47It appears to me this need has long since been met by IterableCSVToBean. It iterates, and it works on a line-by-line basis instead of reading everything into memory at once. I'm closing this ticket. If I am mistaken, simply post a comment to this ticket and I will reopen it and examine it.