![]() |
FirstModulAR 0.1.0
|
Circular buffer data structure for storing audio samples. More...
Public Member Functions | |
| CircularBuffer (int size) | |
| Initializes a new instance of the CircularBuffer class with the specified size. | |
| void | Enqueue (T item) |
| Enqueues an item into the buffer. | |
| void | EnqueueArray (T[] items) |
| Enqueues an array of items into the buffer. | |
| T | Dequeue () |
| Dequeues an item from the buffer. | |
| T[] | DequeueArray (int count) |
| Dequeues an array of items from the buffer. | |
| T | Peek () |
| Peeks at the item at the head of the buffer without dequeuing it. | |
| T[] | PeekAll () |
| Peeks at all items in the buffer without dequeuing them. | |
Properties | |
| int | Count [get] |
| Gets the number of items currently in the buffer. | |
Circular buffer data structure for storing audio samples.
| T | The type of data to store in the buffer. |
|
inline |
Initializes a new instance of the CircularBuffer class with the specified size.
| size | The size of the buffer. |
|
inline |
Dequeues an item from the buffer.
| InvalidOperationException | Thrown when the buffer is empty. |
|
inline |
Dequeues an array of items from the buffer.
| count | The number of items to dequeue. |
| InvalidOperationException | Thrown when the buffer does not contain enough items. |
|
inline |
Enqueues an item into the buffer.
| item | The item to enqueue. |
|
inline |
Enqueues an array of items into the buffer.
| items | The array of items to enqueue. |
| InvalidOperationException | Thrown when the input array is too large to fit in the buffer. |
|
inline |
Peeks at the item at the head of the buffer without dequeuing it.
| InvalidOperationException | Thrown when the buffer is empty. |
|
inline |
Peeks at all items in the buffer without dequeuing them.
|
get |
Gets the number of items currently in the buffer.