new ReadStream(delegate)
Provides methods to read from a data stream. It's used by things
like
module:vertx/file_system.AsyncFile
and module:vertx/http.HttpServerResponse
and is not typically instantiated
directly.
Parameters:
Name | Type | Description |
---|---|---|
delegate |
external:ReadStream | The Java delegate |
- Source:
Extends
Methods
-
dataHandler(handler)
-
Set a data handler. As data is read, the handler will be called with a Buffer containing the data read.
Parameters:
Name Type Description handler
BodyHandler the handler to call - Inherited From:
- Source:
-
endHandler(handler)
-
Set an end handler. Once the stream has ended, and there is no more data to be read, the handler will be called.
Parameters:
Name Type Description handler
Handler the handler to call - Source:
-
exceptionHandler(handler)
-
Set an exception handler.
Parameters:
Name Type Description handler
Handler the handler to call - Inherited From:
- Source:
-
pause()
-
Pause the
ReadStream
. While the stream is paused, no data will be sent to the data Handler- Inherited From:
- Source:
-
resume()
-
Resume reading. If the
ReadStream
has been paused, reading will recommence on it.- Inherited From:
- Source: