Package org.hl7.fhir.utilities
Class CSVReader
java.lang.Object
java.io.Reader
java.io.InputStreamReader
org.hl7.fhir.utilities.CSVReader
- All Implemented Interfaces:
Closeable,AutoCloseable,Readable
- Direct Known Subclasses:
CSVProcessor.DataReader
Baseclass for readers that read data from files in comma separated file format
- Author:
- Ewout
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncell(int index) voidcheckColumn(int i, String name, String desc) String[]getCells()protected static Stringcharbooleanbooleanbooleanbooleanline()protected booleanparseBoolean(String column) String[]Split one line in a CSV file into its cells.String[]voidsetDelimiter(char delimiter) voidsetDoingQuotes(boolean doingQuotes) voidsetMultiline(boolean multiline) splitString(String text) value(int i) Methods inherited from class java.io.InputStreamReader
close, getEncoding, read, read, read, readyMethods inherited from class java.io.Reader
mark, markSupported, nullReader, read, reset, skip, transferTo
-
Constructor Details
-
CSVReader
- Throws:
FHIRExceptionIOException
-
-
Method Details
-
readHeaders
- Throws:
IOExceptionFHIRException
-
line
- Throws:
IOExceptionFHIRException
-
has
-
cell
-
cell
-
parseBoolean
-
getColumn
-
parseLine
Split one line in a CSV file into its cells. Comma's appearing in double quoted strings will not be seen as a separator.- Returns:
- Throws:
IOExceptionFHIRException
-
checkColumn
- Throws:
FHIRException
-
value
-
getDelimiter
-
setDelimiter
-
isMultiline
-
setMultiline
-
isDoingQuotes
-
setDoingQuotes
-
getCells
-
splitString
-