public class AmqpReceiverOptions extends Object
Constructor and Description |
---|
AmqpReceiverOptions() |
AmqpReceiverOptions(AmqpReceiverOptions other) |
AmqpReceiverOptions(JsonObject json) |
Modifier and Type | Method and Description |
---|---|
AmqpReceiverOptions |
addCapability(String capability)
Adds a desired capability.
|
List<String> |
getCapabilities()
Gets the list of desired capabilities for the source.
|
String |
getLinkName() |
int |
getMaxBufferedMessages() |
String |
getQos()
Gets the local QOS config, values can be
null , AT_MOST_ONCE or AT_LEAST_ONCE . |
boolean |
isAutoAcknowledgement() |
boolean |
isDurable() |
boolean |
isDynamic() |
AmqpReceiverOptions |
setAutoAcknowledgement(boolean auto)
Sets the auto-acknowledgement.
|
AmqpReceiverOptions |
setCapabilities(List<String> capabilities)
Sets the list of desired capabilities
A registry of commonly defined source capabilities and their meanings is maintained at
AMQP Source Capabilities.
|
AmqpReceiverOptions |
setDurable(boolean durable)
Sets the durability.
|
AmqpReceiverOptions |
setDynamic(boolean dynamic)
Sets whether the link remote terminus to be used should indicate it is
'dynamic', requesting the peer names it with a dynamic address.
|
AmqpReceiverOptions |
setLinkName(String linkName) |
AmqpReceiverOptions |
setMaxBufferedMessages(int maxBufferSize)
Sets the max buffered messages.
|
AmqpReceiverOptions |
setQos(String qos)
Sets the local QOS config.
|
JsonObject |
toJson() |
public AmqpReceiverOptions()
public AmqpReceiverOptions(AmqpReceiverOptions other)
public AmqpReceiverOptions(JsonObject json)
public JsonObject toJson()
public String getLinkName()
public AmqpReceiverOptions setLinkName(String linkName)
public boolean isDynamic()
public AmqpReceiverOptions setDynamic(boolean dynamic)
The address provided by the peer can then be inspected using the
AmqpReceiver.address()
method on the AmqpReceiver
received once opened.
dynamic
- true if the link should request a dynamic terminus addresspublic String getQos()
null
, AT_MOST_ONCE
or AT_LEAST_ONCE
.public AmqpReceiverOptions setQos(String qos)
qos
- the local QOS config. Accepted values are: null
, AT_MOST_ONCE
or AT_LEAST_ONCE
.public List<String> getCapabilities()
public AmqpReceiverOptions setCapabilities(List<String> capabilities)
capabilities
- the set of capabilities.public AmqpReceiverOptions addCapability(String capability)
capability
- the capability to add, must not be null
public boolean isDurable()
public AmqpReceiverOptions setDurable(boolean durable)
Passing true
sets the expiry policy of the source to NEVER
and the durability of the source
to UNSETTLED_STATE
.
durable
- whether or not the receiver must indicate it's durablepublic int getMaxBufferedMessages()
public AmqpReceiverOptions setMaxBufferedMessages(int maxBufferSize)
maxBufferSize
- the max buffered size, must be positive. If not set, default credit is used.AmqpReceiverOptions
instance.public boolean isAutoAcknowledgement()
true
if the auto-acknowledgement is enabled, false
otherwise.public AmqpReceiverOptions setAutoAcknowledgement(boolean auto)
false
, the messages must
be acknowledged explicitly using AmqpMessage.accepted()
, AmqpMessage.released()
and
AmqpMessage.rejected()
.auto
- whether or not the auto-acknowledgement should be enabled.AmqpReceiverOptions
instance.Copyright © 2020 Eclipse. All rights reserved.