Skip to content

v3.0.0

Compare
Choose a tag to compare
@osiegmar osiegmar released this 10 Jan 21:58
· 120 commits to main since this release

Added

  • IndexedCsvReader for random access to CSV files
  • FieldModifier for modifying fields while reading CSV files
  • Allow custom quote strategies for CsvWriter
  • CsvCallbackHandler for more flexible usage of CsvReader
  • Support for optional BOM header when reading CSV files
  • Method NamedCsvRecord.findField for optional field access
  • Allow READ comment strategy for CSV data with a header
  • Metadata for OSGi capability

Changed

  • Updated from Java 8 to Java 11
  • Updated naming (rows/lines -> records, columns -> fields, differentiate between lines and records)
  • NamedCsvReader replaced by CsvReader.builder().ofNamedCsvRecord()
  • build methods in CsvReaderBuilder with callback handlers and ofCsvRecord / ofNamedCsvRecord as convenience methods
  • Rename errorOnDifferentFieldCount() to ignoreDifferentFieldCount()
  • QuoteStrategy is now an interface – defaults are provided by QuoteStrategies
  • Throw CsvParseException instead of IOException when maximum field size is exceeded
  • NamedCsvRecord extends CsvRecord and provides more access methods
  • Raised the maximum field size to 16 MiB to match SUPER data type capabilities of Amazon Redshift
  • Limit the maximum field count per record to 16,384 to prevent OutOfMemoryErrors
  • Limit the maximum record size to 64 MiB to prevent OutOfMemoryErrors
  • Several performance improvements
  • Improved documentation and error messages

Removed

  • Removed isEmpty() in CsvRecord as it was formerly only used for skipping empty records

Fixed

  • Do not throw an exception when reading comments while enabling different field count checking