UNPKG

@clickup/ent-framework

Version:

A PostgreSQL graph-database-alike library with microsharding and row-level security

23 lines 1.33 kB
import type { QueryAnnotation } from "../abstract/QueryAnnotation"; import { QueryBase } from "../abstract/QueryBase"; import type { Schema } from "../abstract/Schema"; import type { LoadByInput, Row, Table, UniqueKey } from "../types"; import type { PgClient } from "./PgClient"; import { PgRunner } from "./PgRunner"; export declare class PgQueryLoadBy<TTable extends Table, TUniqueKey extends UniqueKey<TTable>> extends QueryBase<TTable, LoadByInput<TTable, TUniqueKey>, Row<TTable> | null, PgClient> { /** @ignore */ readonly RUNNER_CLASS: typeof PgRunnerLoadBy; } declare class PgRunnerLoadBy<TTable extends Table, TUniqueKey extends UniqueKey<TTable>> extends PgRunner<TTable, LoadByInput<TTable, TUniqueKey>, Row<TTable> | null> { static readonly IS_WRITE = false; private builders; readonly op = "SELECT_UNIQ"; readonly maxBatchSize = 200; readonly default: null; constructor(schema: Schema<TTable>, client: PgClient); key(input: LoadByInput<TTable, TUniqueKey>): string; runSingle(input: LoadByInput<TTable, TUniqueKey>, annotations: QueryAnnotation[]): Promise<Row<TTable> | undefined>; runBatch(inputs: Map<string, LoadByInput<TTable, TUniqueKey>>, annotations: QueryAnnotation[]): Promise<Map<string, Row<TTable>>>; } export {}; //# sourceMappingURL=PgQueryLoadBy.d.ts.map