资 源 简 介
Schweigerconsulting CSV Parser
Parsing csv files with comfort.
Read all data from first column:
```
InputStream is = new BufferedInputStream(new FileInputStream(
"test/input/simple.csv"));
Reader reader = new InputStreamReader(is);
CsvReader csv = new CsvReader(reader, false);
csv.parse();
List recordList = csv.readAll();
for (int i = 0; i < recordList.get(0).size(); i++) {
System.out.println(recordList.get(0).getString(i));
}
```
Get column index of given column name:
```
InputStream is = new BufferedInputStream(new FileInputStream(
"test/input/simple-test.csv"));
Reader reader = new InputStreamReader(is);
CsvReader csv = new CsvReader(reader, true);
csv.parse();
System.out.println(csv.getColumnIndex("phone"));
```