alphaTab.io.IReadable
Represents a stream of binary data that can be read from.
interface IReadablePropertiesโ
lengthโ
Gets the total number of bytes contained in the stream.
- JavaScript
- C#
- Kotlin
readonly length: number;double Length { get; }val length: Doublepositionโ
Gets or sets the current read position relative in the stream.
- JavaScript
- C#
- Kotlin
position: number;double Position { get; set; }var position: DoubleMethodsโ
readโ
Reads the given number of bytes from the stream into the given buffer.
- JavaScript
- C#
- Kotlin
read(buffer: Uint8Array, offset: number, count: number): numberdouble Read(Uint8Array buffer, double offset, double count)fun read(buffer: Uint8Array, offset: Double, count: Double): Double| Parameter | Summary |
|---|---|
bufferAll | The buffer to fill. |
offsetAll | The offset in the buffer where to start writing. |
countAll | The number of bytes to read. |
readAllโ
Reads the remaining data.
- JavaScript
- C#
- Kotlin
readAll(): Uint8ArrayUint8Array ReadAll()fun readAll(): Uint8ArrayreadByteโ
Read a single byte from the data stream.
- JavaScript
- C#
- Kotlin
readByte(): numberdouble ReadByte()fun readByte(): DoubleReturnsโ
The value of the next byte or -1 if there is no more data.
resetโ
Resets the stream for reading the data from the beginning.
- JavaScript
- C#
- Kotlin
reset(): voidvoid Reset()fun reset(): Unitskipโ
Skip the given number of bytes.
- JavaScript
- C#
- Kotlin
skip(offset: number): voidvoid Skip(double offset)fun skip(offset: Double): Unit| Parameter | Summary |
|---|---|
offsetAll | The number of bytes to skip. |