- java.lang.Object
-
- io.vertx.mutiny.amqp.AmqpReceiver
-
- All Implemented Interfaces:
io.vertx.mutiny.core.streams.ReadStream<AmqpMessage>,io.vertx.mutiny.core.streams.StreamBase
public class AmqpReceiver extends Object implements io.vertx.mutiny.core.streams.ReadStream<AmqpMessage>
Interface used to consume AMQP message as a stream of message. Back pressure is implemented using AMQP credits. NOTE: This class has been automatically generated from theoriginalnon Mutiny-ified interface using Vert.x codegen.
-
-
Field Summary
Fields Modifier and Type Field Description static io.smallrye.mutiny.vertx.TypeArg<AmqpReceiver>__TYPE_ARG
-
Constructor Summary
Constructors Constructor Description AmqpReceiver(io.vertx.amqp.AmqpReceiver delegate)AmqpReceiver(Object delegate)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Stringaddress()io.smallrye.mutiny.Uni<Void>close()Closes the receiver.VoidcloseAndAwait()Blocking variant ofclose().voidcloseAndForget()Variant ofclose()that ignores the result of the operation.AmqpConnectionconnection()AmqpReceiverendHandler(Runnable endHandler)booleanequals(Object o)AmqpReceiverexceptionHandler(Consumer<Throwable> handler)AmqpReceiverfetch(long amount)io.vertx.amqp.AmqpReceivergetDelegate()AmqpReceiverhandler(Consumer<AmqpMessage> handler)inthashCode()static AmqpReceivernewInstance(io.vertx.amqp.AmqpReceiver arg)AmqpReceiverpause()io.vertx.mutiny.core.streams.Pipe<AmqpMessage>pipe()io.smallrye.mutiny.Uni<Void>pipeTo(io.vertx.mutiny.core.streams.WriteStream<AmqpMessage> dst)VoidpipeToAndAwait(io.vertx.mutiny.core.streams.WriteStream<AmqpMessage> dst)voidpipeToAndForget(io.vertx.mutiny.core.streams.WriteStream<AmqpMessage> dst)AmqpReceiverresume()Iterable<AmqpMessage>toBlockingIterable()Stream<AmqpMessage>toBlockingStream()io.smallrye.mutiny.Multi<AmqpMessage>toMulti()StringtoString()io.vertx.proton.ProtonReceiverunwrap()
-
-
-
Field Detail
-
__TYPE_ARG
public static final io.smallrye.mutiny.vertx.TypeArg<AmqpReceiver> __TYPE_ARG
-
-
Constructor Detail
-
AmqpReceiver
public AmqpReceiver(io.vertx.amqp.AmqpReceiver delegate)
-
AmqpReceiver
public AmqpReceiver(Object delegate)
-
-
Method Detail
-
getDelegate
public io.vertx.amqp.AmqpReceiver getDelegate()
- Specified by:
getDelegatein interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>- Specified by:
getDelegatein interfaceio.vertx.mutiny.core.streams.StreamBase
-
pipe
public io.vertx.mutiny.core.streams.Pipe<AmqpMessage> pipe()
- Specified by:
pipein interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>
-
pipeTo
@CheckReturnValue public io.smallrye.mutiny.Uni<Void> pipeTo(io.vertx.mutiny.core.streams.WriteStream<AmqpMessage> dst)
- Specified by:
pipeToin interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>
-
pipeToAndAwait
public Void pipeToAndAwait(io.vertx.mutiny.core.streams.WriteStream<AmqpMessage> dst)
- Specified by:
pipeToAndAwaitin interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>
-
pipeToAndForget
public void pipeToAndForget(io.vertx.mutiny.core.streams.WriteStream<AmqpMessage> dst)
- Specified by:
pipeToAndForgetin interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>
-
exceptionHandler
public AmqpReceiver exceptionHandler(Consumer<Throwable> handler)
- Specified by:
exceptionHandlerin interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>- Specified by:
exceptionHandlerin interfaceio.vertx.mutiny.core.streams.StreamBase
-
handler
public AmqpReceiver handler(Consumer<AmqpMessage> handler)
- Specified by:
handlerin interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>
-
pause
public AmqpReceiver pause()
- Specified by:
pausein interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>
-
resume
public AmqpReceiver resume()
- Specified by:
resumein interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>
-
fetch
public AmqpReceiver fetch(long amount)
- Specified by:
fetchin interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>
-
endHandler
public AmqpReceiver endHandler(Runnable endHandler)
- Specified by:
endHandlerin interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>
-
address
public String address()
- Returns:
- the address, not
null
-
close
@CheckReturnValue public io.smallrye.mutiny.Uni<Void> close()
Closes the receiver.Unlike the bare Vert.x variant, this method returns a
Uni. Don't forget to subscribe on it to trigger the operation.- Returns:
- the
unifiring the result of the operation when completed, or a failure if the operation failed.
-
closeAndAwait
public Void closeAndAwait()
Blocking variant ofclose().This method waits for the completion of the underlying asynchronous operation. If the operation completes successfully, the result is returned, otherwise the failure is thrown (potentially wrapped in a RuntimeException).
- Returns:
- the Void instance produced by the operation.
-
closeAndForget
public void closeAndForget()
-
connection
public AmqpConnection connection()
- Returns:
- the connection having created the receiver.
-
unwrap
public io.vertx.proton.ProtonReceiver unwrap()
- Returns:
- the underlying ProtonReceiver.
-
toMulti
@CheckReturnValue public io.smallrye.mutiny.Multi<AmqpMessage> toMulti()
- Specified by:
toMultiin interfaceio.vertx.mutiny.core.streams.ReadStream<AmqpMessage>
-
toBlockingIterable
public Iterable<AmqpMessage> toBlockingIterable()
-
toBlockingStream
public Stream<AmqpMessage> toBlockingStream()
-
newInstance
public static AmqpReceiver newInstance(io.vertx.amqp.AmqpReceiver arg)
-
-