Show HN: Automatic Type-Safe CSV (github.com)

1 points by owlstuffing ↗ HN
A compiler plugin enabling seamless CSV access -- your CSV files are types. Use CSV directly and type-safely.

  // Type-safely use resource file "../org/examples/Sales.csv" 
  // without writing extra code or running code gen build steps
  import org.examples.Sales;  
  
  Sales sales = Sales.fromSource();
  for(Sales.SalesItem item: sales) {
    String customer = item.getCustomer();
    ...
  }
Comprehensive support for CSV resource files, supporting extensions csv, tsv, psv, tab.

CSV resource files are the single source of truth. Use CSV-expressed types directly without maintaining a separate set of classes or wedging a code generator into your build.

Additionally, supports JSON Schema to provide constraints for your CSV files.

0 comments

[ 5.6 ms ] story [ 15.3 ms ] thread

No comments yet.