import { Abstract } from '@nestjs/common';
import { DiscoveryService } from '@nestjs/core';
export declare type Registry<T extends ReadonlyArray<unknown>, U> = T extends readonly [infer Head, ...infer Tail] ? Map<Head, Registry<Tail, U>> : U;
export declare const buildTemplateRegistry: <T extends readonly unknown[], U>(discovery: DiscoveryService, { template, keySelector, }: {
    template: Abstract<U>;
    keySelector: (instance: U) => T;
}) => Registry<T, U>;
