import { ResultIteratorClass } from "../addon-bindings"; import { ResultType } from "../addon-types"; /** * ResultIterator represents the result set of a DuckDB query. Instances of this class are returned by the {@link Connection.executeIterator | Connection.executeIterator}. * * @public */ export declare class ResultIterator implements IterableIterator { private resultInterator; /** * * @internal */ constructor(resultInterator: ResultIteratorClass); /** * Fetch the next row * * @remarks * First call returns the first row, when no more rows left `null` is returned. */ fetchRow(): T; /** * Fetch all rows * * @remarks * Note, this may produce a `heap out of bounds` error in case when there is too much data. Either use the {@link ResultIterator.fetchRow | fetchRow} or the {@link Connection.execute | Connection.execute} method when there is a lot of data. */ fetchAllRows(): T[]; /** * Describe the result set schema. */ describe(): Array<[string, string]>; /** * Close the ResultIterator * @remarks * {@link Connection.close | Connection.close} automatically closes all associated ResultIterators. */ close(): void; /** * Get the {@link ResultType | ResultType} of the ResultIterator. This is specified by the {@link IExecuteOptions.forceMaterialized | options} argument on {@link Connection.executeIterator | executeIterator}. */ get type(): ResultType; /** * Returns true if ResultIterator is closed, false otherwise. */ get isClosed(): boolean; next(): IteratorResult; [Symbol.iterator](): this; } //# sourceMappingURL=result-iterator.d.ts.map