Skip to content

Commit c08219e

Browse files
committed
Document reliance of parse(File, CSVFormat) to default encoding
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/csv/trunk@1592604 13f79535-47bb-0310-9956-ffa450edef68
1 parent 129a8db commit c08219e

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/main/java/org/apache/commons/csv/CSVParser.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,11 @@ public final class CSVParser implements Iterable<CSVRecord>, Closeable {
135135
/**
136136
* Creates a parser for the given {@link File}.
137137
*
138+
* <p><strong>Note:</strong> This method internally creates a FileReader using
139+
* {@link FileReader#FileReader(java.io.File)} which in turn relies on the default encoding of the JVM that
140+
* is executing the code. If this is insufficient create a URL to the file and use
141+
* {@link #parse(URL, Charset, CSVFormat)}</p>
142+
*
138143
* @param file
139144
* a CSV file. Must not be null.
140145
* @param format

0 commit comments

Comments
 (0)