eclipse-collections
eclipse-collections copied to clipboard
Primitive and non-primitive circular buffers
I was wondering if it was part of the scope of eclipse collections to provide efficient implementations of circular buffers.
I'm not looking for something with concurrency properties, but simply something to implement circular buffers for primitives and also non-primitives.
Maybe it is the same as a bounded FIFO queue, I'm not exactly sure, I need something where I can add elements and it will keep only the last N elements.
From a datastructure perspective, a dequeue is the right implementation for this and dequeues are certainly in scope. (maybe we'll leave everything else that can be built on top of a dequeue, e.g. a circular buffer, for later)