import { Semaphore } from "@chriscdn/promise-semaphore"; import type { schémaFonctionOublier, schémaFonctionSuivi, schémaRetourFonctionRechercheParN, schémaRetourFonctionRechercheParProfondeur } from "./types.js"; export declare class CacheSuivi { verrou: Semaphore; _cacheSuivi: { [clef: string]: { val?: unknown; requêtes: { [clef: string]: schémaFonctionSuivi; }; fOublier?: schémaFonctionOublier; }; }; _cacheRecherche: { [clef: string]: { val?: unknown[]; taillePrésente: number; requêtes: { [clef: string]: { f: schémaFonctionSuivi; taille: number; }; }; fs?: { fChangerTaille: (n: number) => void; fOublier: schémaFonctionOublier; }; }; }; constructor(); suivre Promise, U>({ adresseFonction, idClient, fOriginale, args, ceciOriginal, }: { adresseFonction: string; idClient: string; fOriginale: T; args: { [clef: string]: unknown; }; ceciOriginal: U; }): Promise; suivreRecherche Promise, U, W extends "profondeur" | "nRésultats", V extends W extends "profondeur" ? schémaRetourFonctionRechercheParProfondeur : schémaRetourFonctionRechercheParN>({ adresseFonction, nomArgTaille, idClient, fOriginale, args, ceciOriginal, par, }: { adresseFonction: string; nomArgTaille: string; idClient: string; fOriginale: T; args: { [clef: string]: unknown; }; ceciOriginal: U; par: W; }): Promise; oublierSuivi({ codeCache, idRequête, }: { codeCache: string; idRequête: string; }): Promise; oublierRecherche({ codeCache, idRequête, }: { codeCache: string; idRequête: string; }): Promise; générerCodeCache({ adresseFonction, idClient, argsClefs, }: { adresseFonction: string; idClient: string; argsClefs: { [clef: string]: unknown; }; }): string; } export declare const cacheSuivi: (_cible: unknown, nom: string, descripteur: unknown) => any; export declare const cacheRechercheParNRésultats: (_cible: unknown, nom: string, descripteur: unknown) => any; export declare const cacheRechercheParProfondeur: (_cible: unknown, nom: string, descripteur: unknown) => any; export declare const envelopper: ({ nom, descripteur, recherche, nomArgTaille, }: { nom: string; descripteur: any; recherche?: "profondeur" | "nR\u00E9sultats"; nomArgTaille?: string; }) => any; export declare const cache: CacheSuivi;