public static enum CsvParser.Header extends Enum<CsvParser.Header>
Enum Constant and Description |
---|
AUTO
Auto detects whether the first line is a header.
|
FIRST_LINE
The first line is the header.
|
NONE
The data contains no header, and the first line is data.
|
Modifier and Type | Method and Description |
---|---|
static CsvParser.Header |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static CsvParser.Header[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final CsvParser.Header AUTO
The first line is interpreted as data only if it can be safely distinguished. If all columns contain strings, then the first line is always interpreted as a header. If the types in the first line do not match the column (e.g. first line string, rest are numbers) then it is interpreted as header. If the types match, and one of them is not a string (e.g. number) then the first line is interpreted as data.
public static final CsvParser.Header FIRST_LINE
public static final CsvParser.Header NONE
A header is automatically generated with the convention given by spreadsheets columns: A, B, ..., Y, Z, AA, AB, ..., AZ, BA, and so on.
public static CsvParser.Header[] values()
for (CsvParser.Header c : CsvParser.Header.values()) System.out.println(c);
public static CsvParser.Header valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullCopyright © 2015. All rights reserved.