import type { Deep, Named, Use } from '@variance-authority/package/help'; import { type Sections } from './store-layout.js'; /** * The rows of one opened store a question names, found by what the question * holds: a name, a file, a specifier. * * The export list and the imports by path are tables of every file: 249,214 * and 141,679 rows on Kibana. A question about one name prints a few dozen of * them, and decoding every row into an object to filter for those cost the * repository per question. So a lookup here compares ids or bytes down a * column, or reads a posting list the store holds, and decodes the rows it * found. Rows come back ascending, the order the whole table is in, so a * caller that filtered the table reads the same rows in the same order. */ /** Which of the three lists an import by path is in. */ export type PathGroup = 'deep' | 'byPath' | 'unfollowed'; /** The rows of one opened store, by name, by file and by specifier. */ export interface StoreRows { /** The export rows written under `name`. */ exportedNamed(name: string): Uint32Array; /** The export rows of the file `at`. */ exportedIn(at: string): Uint32Array; /** The export rows whose own file binds them as `name`, whatever name they are exported under. */ exportedBinding(name: string): readonly number[]; /** One export row, the same value every time it is asked. */ named(row: number): Named; /** The id of the file `path` among the files a row names; none for a path no row names. */ fileId(path: string): number | undefined; /** The imports by path that take `name`. */ pathsTaking(name: string): readonly number[]; /** The imports by path written as exactly `specifier`. */ pathsWritten(specifier: string): readonly number[]; /** One import by path and the list it is in, the same value every time it is asked. */ path(row: number): readonly [Deep, PathGroup]; } /** The decoders of one store's rows, which the whole lists and a single row share. */ export declare function decodersOf({ bytesOf, u32, string, maybe }: Sections): { readonly use: (row: number) => Use; readonly named: (row: number) => Named; readonly path: (row: number) => Deep; }; /** The rows of one opened store, each lookup reading the columns it compares and the rows it found. */ export declare function rowsOf(sections: Sections): StoreRows; //# sourceMappingURL=store-rows.d.ts.map