message: removed old CSV reader
diff: @@ -15,39 +15,6 @@ public class Table {
  this.tableId = tableId;
  }
  -// public static Table fromCSV(Path path, boolean hasHeaders, Types.MinorType... types) throws IOException {
  -// CSVParser parse;
  -// if (hasHeaders) {
  -// parse = CSVFormat.DEFAULT.withFirstRecordAsHeader().parse(new FileReader(path.toFile()));
  -// } else {
  -// parse = CSVFormat.DEFAULT.parse(new FileReader(path.toFile()));
  -// }
  -//
  -// RootAllocator rootAllocator = new RootAllocator();
  -//
  -// // create arrow fields
  -// List<FieldVector> vectors = new ArrayList<>();
  -// for (int i = 0; i < types.length; i++) {
  -// String fieldName = hasHeaders ? parse.getHeaderNames().get(i) : "column-" + i;
  -// FieldVector vector = types[i].getNewVector(
  -// Fields.createDefaultField(fieldName, types[i]),
  -// rootAllocator,
  -// null
  -// );
  -// vectors.add(vector);
  -// vector.allocateNew();
  -// }
  -// for (CSVRecord record : parse) {
  -// for (int i = 0; i < record.size(); i++) {
  -// ValueSetter.parseAndSet(i, record.get(i), types[i], vectors.get(i));
  -// }
  -// }
  -//
  -// Table table = new Table();
  -// table.vectorSchemaRoot = new VectorSchemaRoot(vectors);
  -// return table;
  -// }
  -
  public static Table fromCSV(String path) {
  String uuid = UUID.randomUUID().toString();
  Table.nativeLoadCSV(path, uuid);
  @@ -58,21 +25,29 @@ public class Table {
  return Table.nativeColumnCount(this.tableId);
  }
  + public int getRowCount() {
  + return Table.nativeRowCount(this.tableId);
  + }
  +
  private String getTableId() {
  return tableId;
  }
  // native methods
  - public static native void join(Table table, int tab1Index, int tab2Index);
  + public static native void join(String left, String right, int tab1Index, int tab2Index);
  private static native int nativeColumnCount(String tableId);
  + private static native int nativeRowCount(String tableId);
  +
  public static native void nativeLoadCSV(String path, String id);
  // end of native methods
  public static void main(String[] args) throws IOException {
  NativeLoader.load();
  +
  Table table = Table.fromCSV("/tmp/csv.csv");
  System.out.println(table.getColumnCount());
  + System.out.println(table.getColumnCount());
  }
  }
  