iceberg org.apache.iceberg.parquet.Parquet parquet file read
程序员文章站
2022-03-08 08:05:55
...
org.apache.iceberg.parquet.Parquet#read
public static ReadBuilder read(InputFile file) {
return new ReadBuilder(file);
}
org.apache.iceberg.parquet.Parquet.ReadBuilder
public static class ReadBuilder {
// 文件读范围: [start, start + length).
private Long start = null;
private Long length = null;
// 文件所属 table 的 schema
private Schema schema = null;
// org.apache.iceberg.expressions.Expressions#alwaysTrue
private Expression filter = null;
// reader
private Function<MessageType, ParquetValueReader<?>> readerFunc = null;
// 大小写敏感
private boolean caseSensitive = true;
}
遍历迭代器
CloseableIterable<T> iter = builder.build();
this.currentIterator = iter.iterator();
while (this.currentIterator.hasNext()) {
RowData data = this.currentIterator.next();
res.add(data);
}
上一篇: wpf 无边框窗体