public abstract class AmqpAbstractReceiver extends AmqpAbstractLink<org.apache.qpid.proton.engine.Receiver>
Modifier and Type | Field and Description |
---|---|
protected int |
configuredCredit |
protected org.fusesource.hawtbuf.ByteArrayOutputStream |
current |
protected byte[] |
recvBuffer |
closeActions, closed, endpoint, opened, session
Constructor and Description |
---|
AmqpAbstractReceiver(AmqpSession session,
org.apache.qpid.proton.engine.Receiver endpoint)
Handle create of new AMQP Receiver instance.
|
Modifier and Type | Method and Description |
---|---|
void |
commit(LocalTransactionId txnId)
Handle work necessary on commit of transacted resources associated with
this Link instance.
|
void |
delivery(org.apache.qpid.proton.engine.Delivery delivery)
Called when a new Delivery arrives for the given Link.
|
void |
detach()
Request from the remote peer to detach this resource.
|
void |
flow()
Handles an incoming flow control.
|
void |
flow(int credits)
Provide the receiver endpoint with the given amount of credits.
|
int |
getConfiguredReceiverCredit()
Returns the amount of receiver credit that has been configured for this AMQP
transport.
|
protected abstract void |
processDelivery(org.apache.qpid.proton.engine.Delivery delivery,
org.fusesource.hawtbuf.Buffer deliveryBytes) |
void |
rollback(LocalTransactionId txnId)
Handle work necessary on rollback of transacted resources associated with
this Link instance.
|
addCloseAction, close, close, getEndpoint, getSession, isClosed, isOpened, open, sendToActiveMQ, sendToActiveMQ
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getDestination, setDestination
protected org.fusesource.hawtbuf.ByteArrayOutputStream current
protected final byte[] recvBuffer
protected final int configuredCredit
public AmqpAbstractReceiver(AmqpSession session, org.apache.qpid.proton.engine.Receiver endpoint)
session
- the AmqpSession that servers as the parent of this Link.endpoint
- the Receiver endpoint being managed by this class.public void detach()
AmqpLink
detach
in interface AmqpLink
detach
in class AmqpAbstractLink<org.apache.qpid.proton.engine.Receiver>
public void flow() throws Exception
AmqpLink
Exception
public int getConfiguredReceiverCredit()
public void flow(int credits)
credits
- the credit value to pass on to the wrapped Receiver.public void commit(LocalTransactionId txnId) throws Exception
AmqpLink
txnId
- The Transaction ID being committed.Exception
- if an error occurs while performing the commit.public void rollback(LocalTransactionId txnId) throws Exception
AmqpLink
txnId
- The Transaction ID being rolled back.Exception
- if an error occurs while performing the rollback.public void delivery(org.apache.qpid.proton.engine.Delivery delivery) throws Exception
AmqpLink
delivery
- the newly arrived delivery on this link.Exception
- if an error occurs while processing the new Delivery.protected abstract void processDelivery(org.apache.qpid.proton.engine.Delivery delivery, org.fusesource.hawtbuf.Buffer deliveryBytes) throws Exception
Exception
Copyright © 2005–2019 The Apache Software Foundation. All rights reserved.