Interface CsvTransformer
- All Superinterfaces:
Transformer
- All Known Subinterfaces:
ModelCsvTransformer
- All Known Implementing Classes:
InboundCsvTransformer
,ModelJsonCsvTransformer
,SqlDefCsvTransformer
public interface CsvTransformer extends Transformer
Interface to be implemented by clients who wish to transform a row of
Comma-Separated Values.
-
Method Summary
Modifier and Type Method Description void
transform(CsvRow row, CsvTransformContext context)
Transforms values within a mutable CsvRow.
-
Method Details
-
transform
Transforms values within a mutable CsvRow. In some situations there might be two columns with the same name in a single CSV, for example "State" in ShipmentHeader and ShipmentLine. In situations like these, fields with a conflict will be prefixed with their level name, "ShipmentHeader.State" and "ShipmentLine.State". Fields without such a conflict will be listed without this prefix, for example "ShipmentNumber".- Parameters:
row
- row to be transformed - use theCsvRow.set(String, String)
method to change values on this rowcontext
- provides contextual information around the current CSV Transformation- Throws:
implementers
- should throw this exception if there is any problem transforming the rowCsvTransformException
-