UNPKG

grafast

Version:

Cutting edge GraphQL planning and execution engine

30 lines 1.32 kB
import { $$deepDepSkip } from "../constants.js"; import type { ExecutionDetails, GrafastResultsList, UnbatchedExecutionExtra } from "../interfaces.js"; import { Step } from "../step.js"; import type { StepRepresentingList } from "./connection.js"; declare function unbatchedExecute(_extra: UnbatchedExecutionExtra, list: any[]): any; export declare class FirstStep<TData> extends Step<TData> { static $$export: { moduleName: string; exportName: string; }; allowMultipleOptimizations: boolean; unbatchedExecute?: typeof unbatchedExecute; constructor(parentPlan: StepRepresentingList<TData>, isArray?: boolean); [$$deepDepSkip](): Step; execute({ indexMap, values: [values0], }: ExecutionDetails<[ReadonlyArray<TData>]>): GrafastResultsList<TData>; deduplicate(peers: FirstStep<TData>[]): FirstStep<TData>[]; optimize(): any; } /** * A plan that resolves to the first entry in the list returned by the given * plan. * * @param plan - the list plan * @param array - set this true if the plan represents an array (or * null/undefined) - i.e. it' won't be an (async) iterable - to enable greater * optimization */ export declare function first<TData>(plan: StepRepresentingList<TData>, array?: boolean): FirstStep<TData>; export {}; //# sourceMappingURL=first.d.ts.map