Skip to content

Commit 68e75ee

Browse files
committed
[CSV] deprecated setStrategy, made most private members final
git-svn-id: https://svn.apache.org/repos/asf/jakarta/commons/sandbox/csv/trunk@483576 13f79535-47bb-0310-9956-ffa450edef68
1 parent a05816d commit 68e75ee

1 file changed

Lines changed: 7 additions & 5 deletions

File tree

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

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -69,16 +69,17 @@ public class CSVParser {
6969
private static final String[] EMPTY_STRING_ARRAY = new String[0];
7070

7171
// the input stream
72-
private ExtendedBufferedReader in;
72+
private final ExtendedBufferedReader in;
7373

74+
// TODO: this can be made final if setStrategy is removed
7475
private CSVStrategy strategy;
7576

7677
// the following objects are shared to reduce garbage
7778
/** A record buffer for getLine(). Grows as necessary and is reused. */
78-
private ArrayList record = new ArrayList();
79-
private Token reusableToken = new Token();
80-
private CharBuffer wsBuf = new CharBuffer();
81-
private CharBuffer code = new CharBuffer(4);
79+
private final ArrayList record = new ArrayList();
80+
private final Token reusableToken = new Token();
81+
private final CharBuffer wsBuf = new CharBuffer();
82+
private final CharBuffer code = new CharBuffer(4);
8283

8384

8485
/**
@@ -567,6 +568,7 @@ protected int unicodeEscapeLexer(int c) throws IOException {
567568
* Sets the specified CSV Strategy
568569
*
569570
* @return current instance of CSVParser to allow chained method calls
571+
* @deprecated
570572
*/
571573
public CSVParser setStrategy(CSVStrategy strategy) {
572574
this.strategy = strategy;

0 commit comments

Comments
 (0)