Reader is a CSV reader. It wraps a csv.Reader and provides additional functionality such as the ability to stop reading at a specific line.
| 13 | // |
| 14 | // It wraps a csv.Reader and provides additional functionality such as the ability to stop reading at a specific line. |
| 15 | type Reader struct { |
| 16 | csv *csv.Reader |
| 17 | |
| 18 | // currentLine tracks the current line number. |
| 19 | currentLine atomic.Int64 |
| 20 | |
| 21 | // options holds the reader's options. |
| 22 | options options |
| 23 | |
| 24 | // columnNames stores the column names when the asObjects option is enabled |
| 25 | // in order to be able to map each row values to their corresponding column. |
| 26 | columnNames []string |
| 27 | } |
| 28 | |
| 29 | // NewReaderFrom creates a new CSV reader from the provided io.Reader. |
| 30 | // |
nothing calls this directly
no outgoing calls
no test coverage detected