Vertx.setTimer(long, io.vertx.core.Handler<java.lang.Long>)
/Vertx.setPeriodic(long, io.vertx.core.Handler<java.lang.Long>)
instead. RxJava like integrations should use the Vert.x scheduler integration.@Deprecated public interface TimeoutStream extends ReadStream<Long>
Handler
will be call when the timer is fired,
it can be once or several times depending on the nature of the timer related to this stream. The
ReadStream.endHandler(Handler)
will be called after the timer handler has been called.
Pausing the timer inhibits the timer shots until the stream is resumed. Setting a null handler callback cancels the timer.
Modifier and Type | Method and Description |
---|---|
void |
cancel()
Deprecated.
Cancels the timeout.
|
TimeoutStream |
endHandler(Handler<Void> endHandler)
Deprecated.
Set an end handler.
|
TimeoutStream |
exceptionHandler(Handler<Throwable> handler)
Deprecated.
Set an exception handler on the read stream.
|
TimeoutStream |
fetch(long amount)
Deprecated.
Fetch the specified
amount of elements. |
TimeoutStream |
handler(Handler<Long> handler)
Deprecated.
Set a data handler.
|
TimeoutStream |
pause()
Deprecated.
Pause the
ReadStream , it sets the buffer in fetch mode and clears the actual demand. |
TimeoutStream |
resume()
Deprecated.
Resume reading, and sets the buffer in
flowing mode. |
collect, pipe, pipeTo, pipeTo
TimeoutStream exceptionHandler(Handler<Throwable> handler)
ReadStream
exceptionHandler
in interface ReadStream<Long>
exceptionHandler
in interface StreamBase
handler
- the exception handlerTimeoutStream handler(Handler<Long> handler)
ReadStream
handler
in interface ReadStream<Long>
TimeoutStream pause()
ReadStream
ReadStream
, it sets the buffer in fetch
mode and clears the actual demand.
While it's paused, no data will be sent to the data handler
.
pause
in interface ReadStream<Long>
TimeoutStream resume()
ReadStream
flowing
mode.
If the ReadStream
has been paused, reading will recommence on it.resume
in interface ReadStream<Long>
TimeoutStream fetch(long amount)
ReadStream
amount
of elements. If the ReadStream
has been paused, reading will
recommence with the specified amount
of items, otherwise the specified amount
will
be added to the current stream demand.fetch
in interface ReadStream<Long>
TimeoutStream endHandler(Handler<Void> endHandler)
ReadStream
endHandler
in interface ReadStream<Long>
void cancel()
handler(Handler)
with a null
argument.Copyright © 2024 Eclipse. All rights reserved.