export declare class RingBuffer<T> {
    private _capacity;
    private buffer;
    private head;
    private _size;
    constructor(_capacity: number);
    push(value: T): T | undefined;
    pushMany(values: T[]): T[];
    get(index: number): T | undefined;
    peek(): T | undefined;
    peekOldest(): T | undefined;
    [Symbol.iterator](): Iterator<T>;
    forEach(callback: (value: T, index: number) => void): void;
    toArray(): T[];
    resize(newCapacity: number): T[];
    /**
     * Update items in place. The updater receives each matching item and returns
     * the replacement. Returns the previous values of updated items.
     * O(n) scan, no compaction needed — buffer positions stay stable.
     */
    update(predicate: (item: T) => boolean, updater: (item: T) => T): T[];
    /**
     * Remove items matching a predicate. Returns removed items.
     * O(n) scan + compaction. Size decreases; capacity stays the same.
     */
    remove(predicate: (item: T) => boolean): T[];
    clear(): void;
    get size(): number;
    get capacity(): number;
    get full(): boolean;
}
