1 import Constants from
'./Constants';
3 export default class CircularArray
<T
> extends Array<T
> {
6 constructor(size
: number = Constants
.MAXIMUM_MEASUREMENTS_NUMBER
) {
11 push(...items
: T
[]): number {
12 while (this.length
> this.size
) {
15 return super.push(...items
);
18 unshift(...items
: T
[]): number {
19 while (this.length
> this.size
) {
22 return super.unshift(...items
);