1
0
Fork 0
mirror of https://github.com/codedread/bitjs synced 2025-10-05 10:29:24 +02:00

Make skip() return the ByteStream, for chaining. Document the tee() method.

This commit is contained in:
Jeff Schiller 2024-01-04 22:39:25 +09:00
parent b72e629d8a
commit 208b69a65d
3 changed files with 29 additions and 5 deletions

View file

@ -297,6 +297,7 @@ export class ByteStream {
/**
* Skips n bytes in the stream.
* @param {number} n The number of bytes to skip. Must be a positive integer.
* @returns {ByteStream} Returns this ByteStream for chaining.
*/
skip(n) {
const num = parseInt(n, 10);
@ -313,6 +314,7 @@ export class ByteStream {
}
this.movePointer_(n);
return this;
}
/**