()
| 116 | } |
| 117 | |
| 118 | public toArray(): Uint8Array { |
| 119 | const copy: Uint8Array = new Uint8Array(this.length); |
| 120 | copy.set(this._buffer.subarray(0, 0 + this.length), 0); |
| 121 | return copy; |
| 122 | } |
| 123 | |
| 124 | public copyTo(destination: IWriteable) { |
| 125 | destination.write(this._buffer, 0, this.length); |
no test coverage detected