shared void dataHandler(void onData(Buffer buffer))
Set a data handler. As data is read, the handler will be called with the data.
shared void endHandler(void onEnd())
Set an end handler. Once the stream has ended, and there is no more data to be read, this handler will be called.
shared void exceptionHandler(void onException(Throwable t))
Set an exception handler.
shared void pause()
ReadStream. While the stream is paused, no data will be sent to the
shared Pump pump(WriteStream to, Integer? writeQueueMaxSize = null)
Create a new
Pump with this
ReadStream and the given
shared void resume()
Resume reading. If the
ReadStream has been paused, reading will recommence on it.