/** * @copyright Sister Software * @license AGPL-3.0 * @author Teffen Ellis, et al. * @file Promise-based parquet reads. The iterator-based reads live in `./streams`. * * {@linkcode readParquetRows} throws when the file is missing. {@linkcode tryReadParquetRows} returns `null`. * Both throw for an unreadable file, so a caller cannot mistake a read failure for an empty file. */ import type { PathBuilderLike } from "path-ts"; import { type ParquetRowStreamOptions } from "#parquet/streams"; /** * Reads every row of a parquet file into memory. * * Use {@linkcode openParquetRowStream} for a file too large to hold in memory. * * @throws When the file is missing or `columns` includes a column the file lacks. */ export declare function readParquetRows(path: PathBuilderLike, options?: ParquetRowStreamOptions): Promise; /** * Reads every row of a parquet file, or returns `null` when the file is missing. * * @throws When the file cannot be parsed or `columns` includes a column the file lacks. */ export declare function tryReadParquetRows(path: PathBuilderLike, options?: ParquetRowStreamOptions): Promise; /** * Counts the rows of a parquet file from its metadata, so the cost stays flat as the row count grows. * * The function opens its own DuckDB connection. * * @throws When the file is missing. */ export declare function countParquetRows(path: PathBuilderLike): Promise; /** * Returns a parquet file's column names in file order. * * The query uses `DESCRIBE`, which lists logical columns. * `parquet_schema` lists physical leaves instead, where a list column such as * `tokens` appears only as its `element` child. * * @throws When the file is missing. */ export declare function parquetColumnNames(path: PathBuilderLike): Promise; //# sourceMappingURL=readers.d.ts.map