()
| 2385 | this._array[this._getCyclicIndex(this._length)] = e3, this._length === this._maxLength ? (this._startIndex = ++this._startIndex % this._maxLength, this.onTrimEmitter.fire(1)) : this._length++; |
| 2386 | } |
| 2387 | recycle() { |
| 2388 | if (this._length !== this._maxLength) throw new Error("Can only recycle when the buffer is full"); |
| 2389 | return this._startIndex = ++this._startIndex % this._maxLength, this.onTrimEmitter.fire(1), this._array[this._getCyclicIndex(this._length - 1)]; |
| 2390 | } |
| 2391 | get isFull() { |
| 2392 | return this._length === this._maxLength; |
| 2393 | } |
no test coverage detected