io.vertx.amqp

## Class AmqpReceiverOptions

- java.lang.Object
- - io.vertx.amqp.AmqpReceiverOptions

-     public class AmqpReceiverOptions
      extends Object

  Configures the AMQP Receiver.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `AmqpReceiverOptions()`
    `AmqpReceiverOptions(AmqpReceiverOptions other)`
    `AmqpReceiverOptions(JsonObject json)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    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()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### AmqpReceiverOptions

          public AmqpReceiverOptions()

    - #### AmqpReceiverOptions

          public AmqpReceiverOptions(AmqpReceiverOptions other)

    - #### AmqpReceiverOptions

          public AmqpReceiverOptions(JsonObject json)

  - ### Method Detail

    - #### toJson

          public JsonObject toJson()

    - #### getLinkName

          public String getLinkName()

    - #### setLinkName

          public AmqpReceiverOptions setLinkName(String linkName)

    - #### isDynamic

          public boolean isDynamic()

      Returns:
        whether the receiver is using a dynamic address.

    - #### setDynamic

          public 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.

      The address provided by the peer can then be inspected using the `AmqpReceiver.address()` method on the `AmqpReceiver` received once opened.

      Parameters:
        `dynamic` - true if the link should request a dynamic terminus address
      Returns:
        the options

    - #### getQos

          public String getQos()

      Gets the local QOS config, values can be `null`, `AT_MOST_ONCE` or `AT_LEAST_ONCE`.
      Returns:
        the local QOS config.

    - #### setQos

          public AmqpReceiverOptions setQos(String qos)

      Sets the local QOS config.
      Parameters:
        `qos` - the local QOS config. Accepted values are: `null`, `AT_MOST_ONCE` or `AT_LEAST_ONCE`.
      Returns:
        the options.

    - #### getCapabilities

          public List<String> getCapabilities()

      Gets the list of desired capabilities for the source. A registry of commonly defined source capabilities and their meanings is maintained at AMQP Source Capabilities.
      Returns:
        the list of capabilities, empty if none.

    - #### setCapabilities

          public 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.
      Parameters:
        `capabilities` - the set of capabilities.
      Returns:
        the options

    - #### addCapability

          public AmqpReceiverOptions addCapability(String capability)

      Adds a desired capability. A registry of commonly defined source capabilities and their meanings is maintained at AMQP Source Capabilities.
      Parameters:
        `capability` - the capability to add, must not be `null`
      Returns:
        the options

    - #### isDurable

          public boolean isDurable()

      Returns:
        if the receiver is durable.

    - #### setDurable

          public AmqpReceiverOptions setDurable(boolean durable)

      Sets the durability.

      Passing `true` sets the expiry policy of the source to `NEVER` and the durability of the source to `UNSETTLED_STATE`.

      Parameters:
        `durable` - whether or not the receiver must indicate it's durable
      Returns:
        the options.

    - #### getMaxBufferedMessages

          public int getMaxBufferedMessages()

      Returns:
        the max buffered messages

    - #### setMaxBufferedMessages

          public AmqpReceiverOptions setMaxBufferedMessages(int maxBufferSize)

      Sets the max buffered messages. This message can be used to configure the initial credit of a receiver.
      Parameters:
        `maxBufferSize` - the max buffered size, must be positive. If not set, default credit is used.
      Returns:
        the current `AmqpReceiverOptions` instance.

    - #### isAutoAcknowledgement

          public boolean isAutoAcknowledgement()

      Returns:
        `true` if the auto-acknowledgement is enabled, `false` otherwise.

    - #### setAutoAcknowledgement

          public AmqpReceiverOptions setAutoAcknowledgement(boolean auto)

      Sets the auto-acknowledgement. When enabled (default), the messages are automatically acknowledged. If set to `false`, the messages must be acknowledged explicitly using `AmqpMessage.accepted()`, `AmqpMessage.released()` and `AmqpMessage.rejected()`.
      Parameters:
        `auto` - whether or not the auto-acknowledgement should be enabled.
      Returns:
        the current `AmqpReceiverOptions` instance.

Copyright © 2020 Eclipse. All rights reserved.