public interface Delivery extends Extendable
Modifier and Type | Method and Description |
---|---|
int |
available()
Returns the number of bytes currently available for this delivery, which may not be complete yet, that are still
to either be received by the application or sent by the transport.
|
void |
clear() |
void |
disposition(DeliveryState state)
updates the state of the delivery
The new state may have no on-the-wire effect, if delivery settlement was already communicated to/from the peer.
|
void |
free()
TODO When does an application call this method? Do we really need this?
|
java.lang.Object |
getContext() |
DeliveryState |
getDefaultDeliveryState() |
Link |
getLink() |
DeliveryState |
getLocalState() |
int |
getMessageFormat()
Gets the message-format for this Delivery, representing the 32bit value using an int.
|
DeliveryState |
getRemoteState() |
byte[] |
getTag() |
Delivery |
getWorkNext() |
boolean |
isAborted()
Check for whether the delivery was aborted.
|
boolean |
isBuffered() |
boolean |
isPartial()
Check for whether the delivery is still partial.
|
boolean |
isReadable()
Returns whether this delivery has data ready to be received.
|
boolean |
isSettled()
Returns whether this delivery has been settled.
|
boolean |
isUpdated()
Returns whether this delivery's state or settled flag has ever remotely changed.
|
boolean |
isWritable() |
Delivery |
next() |
int |
pending() |
boolean |
remotelySettled() |
void |
setContext(java.lang.Object o) |
void |
setDefaultDeliveryState(DeliveryState state)
Configures a default DeliveryState to be used if a
received delivery is settled/freed without any disposition
state having been previously applied.
|
void |
setMessageFormat(int messageFormat)
Sets the message-format for this Delivery, representing the 32bit value using an int.
|
void |
settle()
Settles this delivery.
|
attachments
byte[] getTag()
Link getLink()
DeliveryState getLocalState()
DeliveryState getRemoteState()
void disposition(DeliveryState state)
state
- the new delivery statevoid settle()
Connection.getWorkHead()
).
If this delivery is its link's current delivery, the link's current delivery pointer is advanced.boolean isSettled()
settle()
boolean remotelySettled()
void free()
Delivery getWorkNext()
Connection.getWorkHead()
Delivery next()
boolean isWritable()
boolean isReadable()
Receiver.recv(byte[], int, int)
void setContext(java.lang.Object o)
java.lang.Object getContext()
boolean isUpdated()
void clear()
boolean isPartial()
aborted
delivery
will also be considered partial and the full payload won't
be received.
For a sending Delivery, this means the sender link has not been
advanced
to complete the delivery yet.isAborted()
boolean isAborted()
int pending()
boolean isBuffered()
void setDefaultDeliveryState(DeliveryState state)
state
- the default delivery stateDeliveryState getDefaultDeliveryState()
void setMessageFormat(int messageFormat)
See the following for more details:
http://docs.oasis-open.org/amqp/core/v1.0/os/amqp-core-transport-v1.0-os.html#type-transfer
http://docs.oasis-open.org/amqp/core/v1.0/os/amqp-core-transport-v1.0-os.html#type-message-format
http://docs.oasis-open.org/amqp/core/v1.0/os/amqp-core-messaging-v1.0-os.html#section-message-format
http://docs.oasis-open.org/amqp/core/v1.0/os/amqp-core-messaging-v1.0-os.html#definition-MESSAGE-FORMAT
messageFormat
- the message formatint getMessageFormat()
setMessageFormat(int)
int available()
isPartial()
returns false and no content has yet been received by the
application or sent by the transport.Receiver.recv(byte[], int, int)
,
Receiver.recv(org.apache.qpid.proton.codec.WritableBuffer)
,
Sender.send(byte[], int, int)
,
Sender.send(org.apache.qpid.proton.codec.ReadableBuffer)