Package com.azure.core.amqp.models
Class TransactionalDeliveryOutcome
- java.lang.Object
-
- com.azure.core.amqp.models.DeliveryOutcome
-
- com.azure.core.amqp.models.TransactionalDeliveryOutcome
-
public final class TransactionalDeliveryOutcome extends DeliveryOutcome
A transaction delivery outcome.- See Also:
- Transactional state
-
-
Constructor Summary
Constructors Constructor Description TransactionalDeliveryOutcome(AmqpTransaction transaction)Creates an outcome with the given transaction.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DeliveryOutcomegetOutcome()Gets the delivery outcome associated with this transaction.ByteBuffergetTransactionId()Gets the transaction id associated with this delivery outcome.TransactionalDeliveryOutcomesetOutcome(DeliveryOutcome outcome)Sets the outcome associated with this delivery state.-
Methods inherited from class com.azure.core.amqp.models.DeliveryOutcome
getDeliveryState
-
-
-
-
Constructor Detail
-
TransactionalDeliveryOutcome
public TransactionalDeliveryOutcome(AmqpTransaction transaction)
Creates an outcome with the given transaction.- Parameters:
transaction- The transaction.- Throws:
NullPointerException- iftransactionisnull.
-
-
Method Detail
-
getTransactionId
public ByteBuffer getTransactionId()
Gets the transaction id associated with this delivery outcome.- Returns:
- The transaction id.
-
getOutcome
public DeliveryOutcome getOutcome()
Gets the delivery outcome associated with this transaction.- Returns:
- the delivery outcome associated with this transaction,
nullif there is no outcome.
-
setOutcome
public TransactionalDeliveryOutcome setOutcome(DeliveryOutcome outcome)
Sets the outcome associated with this delivery state.- Parameters:
outcome- Outcome associated with this transaction delivery.- Returns:
- The updated
TransactionalDeliveryOutcomeobject. - Throws:
IllegalArgumentException- ifoutcomeis an instance ofTransactionalDeliveryOutcome. Cannot have nested transaction outcomes.
-
-