import type { PrismaClient } from "@prisma/client";
export type ProviderLocationCountRow = {
    locationId: string | null;
    locationName: string;
    locationCode: string | null;
    activeCount: number;
    reserveCount: number;
    totalCount: number;
    cohortCount: number;
    trainingCount: number;
};
export type ProviderCohortLocationRow = {
    trainingId: string;
    trainingTitle: string;
    cohortId: string;
    cohortCode: string;
    cohortName: string;
    locationId: string | null;
    locationName: string;
    locationCode: string | null;
    activeCount: number;
    reserveCount: number;
    totalCount: number;
};
export type ProviderLocationBreakdown = {
    byLocation: ProviderLocationCountRow[];
    byCohort: ProviderCohortLocationRow[];
    totals: {
        activeCount: number;
        reserveCount: number;
        totalCount: number;
    };
};
export type TraineeLocationScope = {
    cohortLocationById: Map<string, bigint | null>;
    trainingDeliverySiteIdsByTrainingId: Map<string, string[]>;
};
/**
 * Cohort location wins when set. If the cohort has no location but the training
 * has exactly one delivery site, use that site. Never use training.locationId when
 * multiple delivery sites exist (ambiguous).
 */
export declare function resolveTraineeDeliveryLocationId(trainee: {
    cohortId: bigint | null;
    trainingId: bigint | null;
    locationId: bigint | null;
}, scope: TraineeLocationScope): bigint | null;
export declare function effectiveCohortLocationId(cohort: {
    locationId: bigint | null;
    trainingId: bigint;
}, scope: TraineeLocationScope): bigint | null;
export declare function buildProviderLocationBreakdown(prisma: PrismaClient, projectId: bigint, trainingProviderId: bigint): Promise<ProviderLocationBreakdown>;
//# sourceMappingURL=providerLocationBreakdown.d.ts.map