diff --git a/src/Types.ts b/src/Types.ts index be292dbf..8061d1ac 100644 --- a/src/Types.ts +++ b/src/Types.ts @@ -272,7 +272,6 @@ export interface IBufferSet extends IEventEmitter { export interface ICircularList extends IEventEmitter { length: number; maxLength: number; - forEach: (callbackfn: (value: T, index: number) => void) => void; get(index: number): T; set(index: number, value: T): void; diff --git a/src/utils/CircularList.ts b/src/utils/CircularList.ts index 6b74971b..1f00ea09 100644 --- a/src/utils/CircularList.ts +++ b/src/utils/CircularList.ts @@ -58,16 +58,6 @@ export class CircularList extends EventEmitter implements ICircularList { this._length = newLength; } - public get forEach(): (callbackfn: (value: T, index: number) => void) => void { - return (callbackfn: (value: T, index: number) => void) => { - let i = 0; - let length = this.length; - for (let i = 0; i < length; i++) { - callbackfn(this.get(i), i); - } - }; - } - /** * Gets the value at an index. *