Class to work with IO streams.
Creates a new stream instance. A Stream is an IO interface that can perform operation like 'Stream.read' and 'Stream.getNextPacket'.
A stream starts with a scheme ('file://', 'http://' etc.)
Continue reading on a stream.
Returns 'null' if there is nothing more to read; Returns an the read bytes upon success.
Go to a position in the stream, counted from the beginning of the stream.
Position to move to
Start reading on a stream.
Read maximal 'packetlen' bytes on the buffer
- Type: Integer
The size of the stream in bytes.
Event: onProgress(buffered, total)
Function that will be called when there is action on the Stream.
The number of bytes that were buffered
The number of bytes that were read
Function that will be called when new data is available on the Stream.
Caught a mistake or want to contribute to the documentation? Edit this page on GitHub!