public class ReceiverImpl extends LinkImpl implements Receiver
| Modifier and Type | Method and Description |
|---|---|
boolean |
advance()
Attempts to advance the current delivery.
|
void |
drain(int credit) |
boolean |
draining() |
void |
flow(int credits)
Adds the specified number of credits.
|
int |
getRemoteCredit()
|
int |
recv(byte[] bytes,
int offset,
int size)
Receive message data for the current delivery.
|
int |
recv(WritableBuffer buffer)
Receive message data for the current delivery.
|
void |
setDrain(boolean drain) |
addCredit, current, delivery, delivery, detach, detached, drained, getConnectionImpl, getCredit, getDesiredCapabilities, getDrain, getName, getOfferedCapabilities, getProperties, getQueued, getReceiverSettleMode, getRemoteDesiredCapabilities, getRemoteOfferedCapabilities, getRemoteProperties, getRemoteReceiverSettleMode, getRemoteSenderSettleMode, getRemoteSource, getRemoteTarget, getSenderSettleMode, getSession, getSource, getTarget, getUnsettled, head, next, setCredit, setDesiredCapabilities, setOfferedCapabilities, setProperties, setReceiverSettleMode, setRemoteSenderSettleMode, setSenderSettleMode, setSource, setTargetattachments, close, free, getCondition, getContext, getLocalState, getRemoteCondition, getRemoteState, open, setCondition, setContextclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcurrent, delivery, delivery, detach, detached, drained, getCredit, getDesiredCapabilities, getDrain, getName, getOfferedCapabilities, getProperties, getQueued, getReceiverSettleMode, getRemoteDesiredCapabilities, getRemoteOfferedCapabilities, getRemoteProperties, getRemoteReceiverSettleMode, getRemoteSenderSettleMode, getRemoteSource, getRemoteTarget, getSenderSettleMode, getSession, getSource, getTarget, getUnsettled, head, next, setDesiredCapabilities, setOfferedCapabilities, setProperties, setReceiverSettleMode, setRemoteSenderSettleMode, setSenderSettleMode, setSource, setTargetclose, free, getCondition, getContext, getLocalState, getRemoteCondition, getRemoteState, open, setCondition, setContextattachmentspublic boolean advance()
Linkadvance in interface Linkadvance in interface Receiveradvance in class LinkImplpublic void flow(int credits)
Receivercredits more deliveries.public int recv(byte[] bytes,
int offset,
int size)
ReceiverDelivery.isPartial(). If
the delivery is partial, the caller should call Receiver.recv(byte[], int, int) again to receive
the additional bytes once the Delivery appears again on the Connection work-list.
TODO might the flags other than IO_WORK in DeliveryImpl also prevent the work list being pruned?
e.g. what if a slow JMS consumer receives a disposition frame containing state=RELEASED? This is not IO_WORK.recv in interface Receiverbytes - the destination array where the message data is writtenoffset - index in the array to start writing data atsize - the maximum number of bytes to writeLink.current()public int recv(WritableBuffer buffer)
Receiverpublic int getRemoteCredit()
Linkcredit count as well as the effect of
any locally queued messages.getRemoteCredit in interface LinkCopyright © 2017 The Apache Software Foundation. All rights reserved.