ByteSequenceStream

A buffer sequence stream to read a sequence of bytes.

Author

Colton Daily

Functions

Link copied to clipboard
abstract fun close()

Closes the stream and prevents it from being read again.

Link copied to clipboard
abstract fun hasRemaining(): Boolean
Link copied to clipboard
abstract operator fun iterator(): Iterator<Byte>
Link copied to clipboard
abstract fun readByte(): Int

Reads the next Byte and returns as an Int.

Link copied to clipboard
abstract fun readChunk(size: Int): ByteArray

Reads the next chunk of the specified size or until it reaches the end of the ByteSequenceStream.

Link copied to clipboard
abstract fun readFloat(): Float

Reads the next Float.

Link copied to clipboard
abstract fun readInt(): Int

Reads the next Int

Link copied to clipboard
abstract fun readShort(): Int

Reads the next Short and returns as an Int.

Link copied to clipboard
abstract fun readUByte(): Int

Reads the next Byte as an unsigned byte and returns as an Int.

Link copied to clipboard
abstract fun readUInt(): Int

Reads the next Int as an unsigned int and returns as an Int.

Link copied to clipboard
abstract fun readUShort(): Int

Reads the next Short as an unsigned short and returns as an Int.

Link copied to clipboard
abstract fun reset()

Resets the chunk iterator back to the beginning.

Link copied to clipboard
abstract fun skip(amount: Int)

Skip the next specified amount of bytes to read

Inheritors

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard