import { OnModuleDestroy, Logger } from '@nestjs/common';
import { BlockchainProviderService } from '../../blockchain-provider';
import { BlocksQueue } from '../blocks-queue';
import type { BlocksCommandExecutor } from '../interfaces';
export declare class BlocksQueueIteratorService implements OnModuleDestroy {
    private readonly blocksCommandExecutor;
    private readonly blockchainProvider;
    private readonly config;
    log: Logger;
    private _queue;
    private _isIterating;
    private batchProcessedPromise;
    protected _resolveNextBatch: () => void;
    private _blocksBatchSize;
    private _timer;
    private readonly _monitoringInterval;
    constructor(blocksCommandExecutor: BlocksCommandExecutor, blockchainProvider: BlockchainProviderService, config: any);
    get resolveNextBatch(): () => void;
    get isIterating(): boolean;
    onModuleDestroy(): void;
    /**
     * Starts iterating over the block queue and processing blocks.
     */
    startQueueIterating(queue: BlocksQueue): Promise<void>;
    private processBatch;
    /**
     * Retrieves the next batch of blocks for processing.
     *
     * Uses maximum batch size approach to ensure optimal performance:
     * - Always processes available blocks (guarantees progress)
     * - Respects memory limits by not exceeding maximum batch size
     * - Prevents resource starvation by taking all available blocks up to the limit
     *
     * This approach is better than minimum batch size because:
     * - No deadlock when blocks are smaller than minimum threshold
     * - Efficient resource utilization
     * - Predictable performance characteristics
     *
     * @returns Promise resolving to array of blocks ready for processing
     */
    private peekNextBatch;
    private initBatchProcessedPromise;
}
