DeferOptions Class

  • java.lang.Object
    • com.azure.messaging.servicebus.models.SettlementOptions
      • com.azure.messaging.servicebus.models.DeferOptions

public final class DeferOptions
extends com.azure.messaging.servicebus.models.SettlementOptions

Options to specify when deferring a ServiceBusReceivedMessage received via PEEK_LOCK.

Constructor Summary

Constructor Description
DeferOptions()

Creates a new instance of options to specify when deferring messages.

Method Summary

Modifier and Type Method and Description
Map<String,Object> getPropertiesToModify()

Gets the message properties to modify while deferring the message.

DeferOptions setPropertiesToModify(Map<String,Object> propertiesToModify)

Sets the message properties to modify while deferring the message.

DeferOptions setTransactionContext(ServiceBusTransactionContext transactionContext)

Sets the ServiceBusTransactionContext to the options.

Methods inherited from com.azure.messaging.servicebus.models.SettlementOptions

com.azure.messaging.servicebus.models.SettlementOptions.getTransactionContext com.azure.messaging.servicebus.models.SettlementOptions.setTransactionContext

Methods inherited from java.lang.Object

Constructor Details

DeferOptions

public DeferOptions()

Creates a new instance of options to specify when deferring messages.

Method Details

getPropertiesToModify

public Map<String,Object> getPropertiesToModify()

Gets the message properties to modify while deferring the message.

Returns:

The message properties to modify while deferring the message.

setPropertiesToModify

public DeferOptions setPropertiesToModify(Map<String,Object> propertiesToModify)

Sets the message properties to modify while deferring the message.

Parameters:

propertiesToModify - Message properties to modify.

Returns:

The updated DeferOptions object.

setTransactionContext

public DeferOptions setTransactionContext(ServiceBusTransactionContext transactionContext)

Sets the ServiceBusTransactionContext to the options.

Overrides:

DeferOptions.setTransactionContext(ServiceBusTransactionContext transactionContext)

Parameters:

transactionContext - The ServiceBusTransactionContext that will be used to defer a message.

Returns:

The updated DeferOptions object.

Applies to