import type { Model } from './model'; /** * TTL (Time To Live) Manager * Manages automatic cleanup of expired documents based on TTL indexes */ export declare class TTLManager { private intervals; /** * Register a TTL index for automatic cleanup * @param model - The model to monitor * @param field - The field containing the timestamp * @param ttlSeconds - Time to live in seconds * @param checkIntervalMs - How often to check for expired documents (default: 60 seconds) */ registerTTLIndex>(model: Model, field: string, ttlSeconds: number, checkIntervalMs?: number): void; /** * Clean up expired documents for a specific field */ private cleanupExpiredDocuments; /** * Unregister a TTL index (stop automatic cleanup) */ unregisterTTLIndex(key: string): void; /** * Clean up all TTL intervals (call on disconnect) */ cleanup(): void; /** * Get the number of active TTL indexes */ getActiveCount(): number; } //# sourceMappingURL=ttl-manager.d.ts.map