[ 
https://issues.apache.org/jira/browse/CSV-167?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15123306#comment-15123306
 ] 

Sebb commented on CSV-167:
--------------------------

I agree with Bruno - there is no code bug here.

I think the problem here is the method isComment() is misleading.

The name and Javadoc both suggest that a CSVRecord may either be a comment or a 
normal record.

However the method just checks whether the record HAS a comment.

So the test case is wrong, it needs to count all records, not just non-comments.
Furthermore, the header is counted as a record.

The Javadoc needs to be corrected.
Possibly consider deprecating isComment and adding hasComment/isCommented 
method.

> Comment line hides next record
> ------------------------------
>
>                 Key: CSV-167
>                 URL: https://issues.apache.org/jira/browse/CSV-167
>             Project: Commons CSV
>          Issue Type: Bug
>          Components: Parser
>    Affects Versions: 1.2
>            Reporter: Rene
>         Attachments: CSVProcessor.java, sample1.csv
>
>
> 1. First CSV record after the comment line is not processed at all (record #2 
> and #7)
> 2. Second/Third line after the first comment line are not recognized as 
> comment lines (record #5 and #6)
> See attached example!



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to