@@ -66,7 +66,7 @@ public class CSVFormat implements Serializable {
6666 public static final CSVFormat DEFAULT =
6767 PRISTINE
6868 .withDelimiter (COMMA )
69- .withEncapsulator (DOUBLE_QUOTE )
69+ .withQuoteChar (DOUBLE_QUOTE )
7070 .withIgnoreEmptyLines (true )
7171 .withLineSeparator (CRLF );
7272
@@ -82,7 +82,7 @@ public class CSVFormat implements Serializable {
8282 public static final CSVFormat RFC4180 =
8383 PRISTINE
8484 .withDelimiter (COMMA )
85- .withEncapsulator (DOUBLE_QUOTE )
85+ .withQuoteChar (DOUBLE_QUOTE )
8686 .withLineSeparator (CRLF );
8787
8888 /**
@@ -98,14 +98,14 @@ public class CSVFormat implements Serializable {
9898 public static final CSVFormat EXCEL =
9999 PRISTINE
100100 .withDelimiter (COMMA )
101- .withEncapsulator (DOUBLE_QUOTE )
101+ .withQuoteChar (DOUBLE_QUOTE )
102102 .withLineSeparator (CRLF );
103103
104104 /** Tab-delimited format, with quote; leading and trailing spaces ignored. */
105105 public static final CSVFormat TDF =
106106 PRISTINE
107107 .withDelimiter (TAB )
108- .withEncapsulator (DOUBLE_QUOTE )
108+ .withQuoteChar (DOUBLE_QUOTE )
109109 .withIgnoreSurroundingSpaces (true )
110110 .withIgnoreEmptyLines (true )
111111 .withLineSeparator (CRLF );
@@ -258,8 +258,8 @@ public Character getQuoteChar() {
258258 * @throws IllegalArgumentException
259259 * thrown if the specified character is a line break
260260 */
261- public CSVFormat withEncapsulator (final char encapsulator ) {
262- return withEncapsulator (Character .valueOf (encapsulator ));
261+ public CSVFormat withQuoteChar (final char quoteChar ) {
262+ return withQuoteChar (Character .valueOf (quoteChar ));
263263 }
264264
265265 /**
@@ -271,11 +271,11 @@ public CSVFormat withEncapsulator(final char encapsulator) {
271271 * @throws IllegalArgumentException
272272 * thrown if the specified character is a line break
273273 */
274- public CSVFormat withEncapsulator (final Character encapsulator ) {
275- if (isLineBreak (encapsulator )) {
274+ public CSVFormat withQuoteChar (final Character quoteChar ) {
275+ if (isLineBreak (quoteChar )) {
276276 throw new IllegalArgumentException ("The quoteChar cannot be a line break" );
277277 }
278- return new CSVFormat (delimiter , encapsulator , quotePolicy , commentStart , escape ,
278+ return new CSVFormat (delimiter , quoteChar , quotePolicy , commentStart , escape ,
279279 ignoreSurroundingSpaces , ignoreEmptyLines , lineSeparator , header );
280280 }
281281
0 commit comments