Package org.eclipse.epsilon.pinset
Class CSVFile
- java.lang.Object
-
- org.eclipse.epsilon.pinset.CSVFile
-
public class CSVFile extends Object
Persists a dataset to a CSV file Adapted from org.apache.commons.text.translate.CsvTranslators https://commons.apache.org/proper/commons-text/jacoco/org.apache.commons.text.translate/CsvTranslators.java.html- Since:
- 2.1
- Author:
- Alfonso de la Vega
-
-
Field Summary
Fields Modifier and Type Field Description static String
CSV_DELIMITER
protected Dataset
dataset
protected String
path
protected PrintWriter
pw
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addRecord(List<String> cellValues)
static String
escapeCSV(String cellValue)
protected void
headerRecord(List<String> columnNames)
protected void
rowRecord(List<ValueWrapper> wrappers)
void
save()
-
-
-
Field Detail
-
CSV_DELIMITER
public static final String CSV_DELIMITER
- See Also:
- Constant Field Values
-
path
protected String path
-
dataset
protected Dataset dataset
-
pw
protected PrintWriter pw
-
-
Method Detail
-
save
public void save() throws FileNotFoundException
- Throws:
FileNotFoundException
-
rowRecord
protected void rowRecord(List<ValueWrapper> wrappers)
-
-