import { ActualAssignment, Username } from '../../core/index.js'; import { MembershipScope } from './soql.js'; /** Split a list into consecutive batches. An empty list yields no batches, so it asks nothing. */ export declare function batched(values: T[]): T[][]; /** * One scope per batch, each carrying a single clause. The query ORs its clauses together, so * asking them one at a time and unioning the answers reads the same rows, in as many * requests as the widest clause needs. */ export declare function splitMembershipScope(scope: MembershipScope): MembershipScope[]; /** * The union of the batches, deduped by record id. One record can satisfy two clauses at * once (held on a managed target, by a managed user), and splitting the clauses is what * turns that into two rows where the single query returned one. */ export declare function distinctAssignments(assignments: ActualAssignment[]): ActualAssignment[]; /** * The batches to query for a username filter. Undefined is the whole org rather than an * empty selection, so it stays one query, with no username clause in it. */ export declare function usernameBatches(usernames: Username[] | undefined): (Username[] | undefined)[]; //# sourceMappingURL=batching.d.ts.map