Proton DotNet
Public Member Functions | Public Attributes | Properties | List of all members
Apache.Qpid.Proton.Client.Implementation.ClientDelivery Class Reference

Client inbound delivery API that wraps the proton resources and provides API to operate on them. More...

Inheritance diagram for Apache.Qpid.Proton.Client.Implementation.ClientDelivery:
Apache.Qpid.Proton.Client.IDelivery

Public Member Functions

IMessage< object > Message ()
 Decodes the payload of the delivery and returns a new message. More...
 
IDelivery Disposition (IDeliveryState state, bool settled)
 Applies the given delivery state to the delivery if not already settled and optionally settles it. More...
 
IDelivery Settle ()
 Settles the delivery with the remote which prevents any further delivery state updates. More...
 
IDelivery Accept ()
 Accepts and settles this delivery. More...
 
IDelivery Modified (bool deliveryFailed, bool undeliverableHere)
 Modifies and settles the delivery applying the failure and routing options. More...
 
IDelivery Reject (string condition, string description)
 Rejects the delivery with an ErrorCondition that contains the provided condition and description information and settles. More...
 
IDelivery Release ()
 Releases and settles this delivery. More...
 
Task< IDeliveryAcceptAsync ()
 Accepts and settles this delivery asynchronously ensuring that the call does not block on any IO or other client operations. More...
 
Task< IDeliveryReleaseAsync ()
 Releases and settles this delivery asynchronously ensuring that the call does not block on any IO or other client operations. More...
 
Task< IDeliveryRejectAsync (string condition, string description)
 Asynchronously rejects the delivery with an ErrorCondition that contains the provided condition and description information and settles. More...
 
Task< IDeliveryModifiedAsync (bool deliveryFailed, bool undeliverableHere)
 Modifies and settles the delivery asynchronously applying the failure and routing options without any blocking due to IO or other client internal operations. More...
 
Task< IDeliveryDispositionAsync (IDeliveryState state, bool settled)
 Applies the given delivery state to the delivery if not already settled and optionally settles it performing all IO and client work asynchronously ensuring that any calls to this method do not block. More...
 
Task< IDeliverySettleAsync ()
 Settles the delivery with the remote which prevents any further delivery state updates asynchronously. More...
 

Public Attributes

IReceiver Receiver => receiver
 
uint MessageFormat => delivery.MessageFormat
 
bool Settled => delivery.IsSettled
 
IDeliveryState State => delivery.State?.ToClientDeliveryState()
 
bool RemoteSettled => delivery.IsRemotelySettled
 
IDeliveryState RemoteState => delivery.RemoteState?.ToClientDeliveryState()
 

Properties

IReadOnlyDictionary< string, object >? Annotations [get]
 
Stream RawInputStream [get]
 
- Properties inherited from Apache.Qpid.Proton.Client.IDelivery
IReceiver Receiver [get]
 Returns the parent receiver instance where this delivery arrived. More...
 
uint MessageFormat [get]
 The message format value that was transmitted with this delivery (default is zero). More...
 
Stream RawInputStream [get]
 Create and return an read-only Stream that reads the raw payload bytes of the given delivery. Calling this method claims the payload of the delivery for the returned Stream and excludes use of the message and annotations API methods of the delivery object. Closing the returned input stream discards any unread bytes from the delivery payload. Calling the message or annotations methods after calling this method will throw a ClientIllegalStateException. More...
 
IReadOnlyDictionary< string, object > Annotations [get]
 Decodes the delivery payload and returns a dictionary containing a copy of any associated delivery annotations that were transmitted with the message payload. More...
 
bool Settled [get]
 Returns true if this delivery has already been settled. More...
 
IDeliveryState State [get]
 Returns the currently set delivery state for this delivery or null if none set. More...
 
bool RemoteSettled [get]
 Returns true if this delivery has already been settled by the remote. More...
 
IDeliveryState RemoteState [get]
 Returns the currently set delivery state for this delivery as set by the remote or null if none set. More...
 

Detailed Description

Client inbound delivery API that wraps the proton resources and provides API to operate on them.

Member Function Documentation

◆ Accept()

IDelivery Apache.Qpid.Proton.Client.Implementation.ClientDelivery.Accept ( )
inline

Accepts and settles this delivery.

Returns
This delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ AcceptAsync()

Task<IDelivery> Apache.Qpid.Proton.Client.Implementation.ClientDelivery.AcceptAsync ( )
inline

Accepts and settles this delivery asynchronously ensuring that the call does not block on any IO or other client operations.

Returns
A Task that returns this delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ Disposition()

IDelivery Apache.Qpid.Proton.Client.Implementation.ClientDelivery.Disposition ( IDeliveryState  state,
bool  settled 
)
inline

Applies the given delivery state to the delivery if not already settled and optionally settles it.

Parameters
statedelivery state to apply to this delivery
settledoptionally settles the delivery
Returns
This delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ DispositionAsync()

Task<IDelivery> Apache.Qpid.Proton.Client.Implementation.ClientDelivery.DispositionAsync ( IDeliveryState  state,
bool  settled 
)
inline

Applies the given delivery state to the delivery if not already settled and optionally settles it performing all IO and client work asynchronously ensuring that any calls to this method do not block.

Parameters
statedelivery state to apply to this delivery
settledoptionally settles the delivery
Returns
A Task that returns this delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ Message()

IMessage<object> Apache.Qpid.Proton.Client.Implementation.ClientDelivery.Message ( )
inline

Decodes the payload of the delivery and returns a new message.

Calling this message claims the payload of the delivery for the returned Message and excludes use of the RawInputStream method of the delivery object. Calling the RawInputStream method after calling this method throws ClientIllegalStateException.

If the incoming message carried any delivery annotations they can be accessed via the Annotations method. Re-sending the returned message will not also send the incoming delivery annotations, the sender must include them in the sender's send call if they are to be forwarded onto the next recipient.

Template Parameters
TBody type of the message
Returns
the decoded message from the delivery payload

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ Modified()

IDelivery Apache.Qpid.Proton.Client.Implementation.ClientDelivery.Modified ( bool  deliveryFailed,
bool  undeliverableHere 
)
inline

Modifies and settles the delivery applying the failure and routing options.

Parameters
deliveryFailedIf the delivery failed on this receiver for some reason
undeliverableHereIf the delivery should not be routed back to this receiver.
Returns
This delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ ModifiedAsync()

Task<IDelivery> Apache.Qpid.Proton.Client.Implementation.ClientDelivery.ModifiedAsync ( bool  deliveryFailed,
bool  undeliverableHere 
)
inline

Modifies and settles the delivery asynchronously applying the failure and routing options without any blocking due to IO or other client internal operations.

Parameters
deliveryFailedIf the delivery failed on this receiver for some reason
undeliverableHereIf the delivery should not be routed back to this receiver.
Returns
A Task that returns this delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ Reject()

IDelivery Apache.Qpid.Proton.Client.Implementation.ClientDelivery.Reject ( string  condition,
string  description 
)
inline

Rejects the delivery with an ErrorCondition that contains the provided condition and description information and settles.

Parameters
conditionThe condition that defines this rejection error
descriptionA description of the rejection cause.
Returns
This delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ RejectAsync()

Task<IDelivery> Apache.Qpid.Proton.Client.Implementation.ClientDelivery.RejectAsync ( string  condition,
string  description 
)
inline

Asynchronously rejects the delivery with an ErrorCondition that contains the provided condition and description information and settles.

Parameters
conditionThe condition that defines this rejection error
descriptionA description of the rejection cause.
Returns
A Task that returns this delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ Release()

IDelivery Apache.Qpid.Proton.Client.Implementation.ClientDelivery.Release ( )
inline

Releases and settles this delivery.

Returns
This delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ ReleaseAsync()

Task<IDelivery> Apache.Qpid.Proton.Client.Implementation.ClientDelivery.ReleaseAsync ( )
inline

Releases and settles this delivery asynchronously ensuring that the call does not block on any IO or other client operations.

Returns
A Task that returns this delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ Settle()

IDelivery Apache.Qpid.Proton.Client.Implementation.ClientDelivery.Settle ( )
inline

Settles the delivery with the remote which prevents any further delivery state updates.

Returns
This delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.

◆ SettleAsync()

Task<IDelivery> Apache.Qpid.Proton.Client.Implementation.ClientDelivery.SettleAsync ( )
inline

Settles the delivery with the remote which prevents any further delivery state updates asynchronously.

Returns
A Task that returns this delivery instance

Implements Apache.Qpid.Proton.Client.IDelivery.


The documentation for this class was generated from the following file: