Rename "encapsulator" to "quoteChar" so we have quoteChar and quotePolicy. Encapsulator makes me want to ask "encapsulate what"? fieldEncapsulator would be better but so verbose, quoteChar feels more to the point to me and provides symmetry with quotePolicy.

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/csv/trunk@1398017 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Gary D. Gregory 2012-10-14 05:10:57 +00:00
parent 0dbb499888
commit 7fd16f353a
1 changed files with 2 additions and 2 deletions

View File

@ -136,7 +136,7 @@ public class CSVPrinter {
private void print(final CharSequence value, final int offset, final int len) throws IOException {
if (format.isQuoting()) {
printAndEncapsulate(value, offset, len);
printAndQuote(value, offset, len);
} else if (format.isEscaping()) {
printAndEscape(value, offset, len);
} else {
@ -191,7 +191,7 @@ public class CSVPrinter {
}
}
void printAndEncapsulate(final CharSequence value, final int offset, final int len) throws IOException {
void printAndQuote(final CharSequence value, final int offset, final int len) throws IOException {
final boolean first = newLine; // is this the first value on this line?
boolean quote = false;
int start = offset;