org.apache.qpid.server.queue
Class SubscriptionImpl
java.lang.Object
org.apache.qpid.server.queue.SubscriptionImpl
- All Implemented Interfaces:
- Subscription
public class SubscriptionImpl
- extends java.lang.Object
- implements Subscription
Encapsulation of a supscription to a queue.
Ties together the protocol session of a subscriber, the consumer tag that
was given out by the broker and the channel id.
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
channel
public final AMQChannel channel
protocolSession
public final AMQProtocolSession protocolSession
consumerTag
public final java.lang.String consumerTag
SubscriptionImpl
public SubscriptionImpl(int channelId,
AMQProtocolSession protocolSession,
java.lang.String consumerTag,
boolean acks)
throws org.apache.qpid.AMQException
- Throws:
org.apache.qpid.AMQException
SubscriptionImpl
public SubscriptionImpl(int channel,
AMQProtocolSession protocolSession,
java.lang.String consumerTag)
throws org.apache.qpid.AMQException
- Throws:
org.apache.qpid.AMQException
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in class java.lang.Object
hashCode
public int hashCode()
- Overrides:
hashCode
in class java.lang.Object
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object
send
public void send(AMQMessage msg,
AMQQueue queue)
throws FailedDequeueException
- This method can be called by each of the publisher threads.
As a result all changes to the channel object must be thread safe.
- Specified by:
send
in interface Subscription
- Parameters:
msg
- queue
-
- Throws:
org.apache.qpid.AMQException
FailedDequeueException
isSuspended
public boolean isSuspended()
- Specified by:
isSuspended
in interface Subscription
queueDeleted
public void queueDeleted(AMQQueue queue)
- Callback indicating that a queue has been deleted.
- Specified by:
queueDeleted
in interface Subscription
- Parameters:
queue
-