Menu

#73 Keep track of and return actual line number position in file

closed
None
5
2015-10-26
2015-10-13
Raphael
No

For user feedback it would be great to determine the actual line number where the CSVReader is currently positioned (e.g. during logging/reporting). Due to multi line reads, this number might differ from the number of calls to readNext().
Solution would be to count the lines in the LineReader class.

Discussion

  • Scott Conway

    Scott Conway - 2015-10-14
    • status: open --> accepted
     
  • Scott Conway

    Scott Conway - 2015-10-14

    Good suggestion - I put that on our todo list in the wiki. It will not be in the next release but hopefully the release after that.

     
  • Scott Conway

    Scott Conway - 2015-10-26

    Added two new methods to CSVReader - getLinesRead which returns the number of lines read (which is what you requested) and getRecordsRead which returns the number of actual records (Array of Strings) returned by CSVReader.

    These have been merged into trunk and will be in the 3.6 release.

     
  • Scott Conway

    Scott Conway - 2015-10-26
    • status: accepted --> closed
    • assigned_to: Scott Conway
     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.