public abstract class CSVFileParser extends GenericFileParser
| Constructor and Description |
|---|
CSVFileParser(char separatorChar)
Constructor
|
CSVFileParser(char separatorChar,
String commentString)
Constructor
|
CSVFileParser(String separatorChar)
Constructor
|
CSVFileParser(String separatorChar,
String commentString)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
dataLine(int lineNumber,
String line)
Specific processing for each data line
|
protected abstract void |
dataLine(int lineNumber,
String line,
String[] fields)
Called for each data line
|
char |
getSeparatorChar()
Returns the separator character
|
commentLine, end, getCommentString, getResult, parse, parse, parse, start, voidLinepublic CSVFileParser(char separatorChar)
separatorChar - the field separatorpublic CSVFileParser(char separatorChar,
String commentString)
separatorChar - the field separatorcommentString - the comment stringpublic CSVFileParser(String separatorChar)
separatorChar - the field separator (use only the first character of the string)public char getSeparatorChar()
protected abstract void dataLine(int lineNumber,
String line,
String[] fields)
lineNumber - the line numberline - the line as it was read from the filefields - array of fieldsprotected void dataLine(int lineNumber,
String line)
GenericFileParserdataLine in class GenericFileParserline - the line to processCopyright © 2016. All rights reserved.