|
|||||||||
| Home >> All >> org >> activemq >> [ service overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.activemq.service
Interface Subscription

- public interface Subscription
A Subscription holds messages to be dispatched to a a Client Consumer
- Version:
- $Revision: 1.1.1.1 $
| Method Summary | |
void |
addMessage(MessageContainer container,
org.activemq.message.ActiveMQMessage message)
If the Subscription is a target for the message, the subscription will add a reference to the message and register an interest in the message to the container |
void |
clear()
Called when the Subscription is discarded |
java.lang.String |
getClientId()
|
java.lang.String |
getConsumerId()
|
int |
getConsumerNumber()
|
org.activemq.message.ActiveMQDestination |
getDestination()
|
MessageIdentity |
getLastMessageIdentity()
Retreives the messageIdentity of the last message sent to this Queue based Subscription |
org.activemq.message.ActiveMQMessage[] |
getMessagesToDispatch()
Retrieve messages to dispatch |
java.lang.String |
getPersistentKey()
Returns the persistent key used to uniquely identify this durable topic subscription |
java.lang.String |
getSelector()
|
java.lang.String |
getSubscriberName()
|
SubscriberEntry |
getSubscriptionEntry()
Lazily creates the persistent entry representation of this subscription |
boolean |
isActive()
|
boolean |
isAtPrefetchLimit()
Indicates the Subscription it's reached it's pre-fetch limit |
boolean |
isBrowser()
Indicates the consumer is a browser only |
boolean |
isDurableTopic()
Indicates the Consumer is a Durable Subscriber |
boolean |
isLocalSubscription()
|
boolean |
isReadyToDispatch()
Indicates if this Subscription has more messages to send to the Consumer |
boolean |
isSameDurableSubscription(org.activemq.message.ConsumerInfo info)
Checks if this subscription is a duplicate durable subscription of the given consumer info |
boolean |
isTarget(org.activemq.message.ActiveMQMessage message)
determines if the Subscription is interested in the message |
boolean |
isWildcard()
|
void |
messageConsumed(org.activemq.message.MessageAck ack)
Indicates a message has been delivered to a MessageConsumer which is typically called for topic based subscriptions |
void |
reset()
Called when an active message consumer has closed. |
void |
setActive(boolean newActive)
set the state of the Subscription |
void |
setActiveConsumer(org.activemq.broker.BrokerClient client,
org.activemq.message.ConsumerInfo info)
Set the active consumer info |
void |
setLastMessageIdentifier(MessageIdentity messageIdentity)
Used for a Queue based Subscription to set the last acknowledged message ID |
| Method Detail |
setActiveConsumer
public void setActiveConsumer(org.activemq.broker.BrokerClient client, org.activemq.message.ConsumerInfo info)
- Set the active consumer info
clear
public void clear()
throws javax.jms.JMSException
- Called when the Subscription is discarded
reset
public void reset()
throws javax.jms.JMSException
- Called when an active message consumer has closed.
getClientId
public java.lang.String getClientId()
getSubscriberName
public java.lang.String getSubscriberName()
getDestination
public org.activemq.message.ActiveMQDestination getDestination()
getSelector
public java.lang.String getSelector()
isActive
public boolean isActive()
setActive
public void setActive(boolean newActive)
throws javax.jms.JMSException
- set the state of the Subscription
getConsumerNumber
public int getConsumerNumber()
getConsumerId
public java.lang.String getConsumerId()
isTarget
public boolean isTarget(org.activemq.message.ActiveMQMessage message) throws javax.jms.JMSException
- determines if the Subscription is interested in the message
addMessage
public void addMessage(MessageContainer container, org.activemq.message.ActiveMQMessage message) throws javax.jms.JMSException
- If the Subscription is a target for the message, the subscription will add a reference to
the message and register an interest in the message to the container
messageConsumed
public void messageConsumed(org.activemq.message.MessageAck ack) throws javax.jms.JMSException
- Indicates a message has been delivered to a MessageConsumer
which is typically called for topic based subscriptions
getMessagesToDispatch
public org.activemq.message.ActiveMQMessage[] getMessagesToDispatch() throws javax.jms.JMSException
- Retrieve messages to dispatch
isReadyToDispatch
public boolean isReadyToDispatch()
throws javax.jms.JMSException
- Indicates if this Subscription has more messages to send to the
Consumer
isAtPrefetchLimit
public boolean isAtPrefetchLimit()
throws javax.jms.JMSException
- Indicates the Subscription it's reached it's pre-fetch limit
isDurableTopic
public boolean isDurableTopic()
throws javax.jms.JMSException
- Indicates the Consumer is a Durable Subscriber
isBrowser
public boolean isBrowser()
throws javax.jms.JMSException
- Indicates the consumer is a browser only
getLastMessageIdentity
public MessageIdentity getLastMessageIdentity() throws javax.jms.JMSException
- Retreives the messageIdentity of the last message sent to this
Queue based Subscription
setLastMessageIdentifier
public void setLastMessageIdentifier(MessageIdentity messageIdentity) throws javax.jms.JMSException
- Used for a Queue based Subscription to set the last acknowledged
message ID
isWildcard
public boolean isWildcard()
getPersistentKey
public java.lang.String getPersistentKey()
- Returns the persistent key used to uniquely identify this durable topic subscription
isSameDurableSubscription
public boolean isSameDurableSubscription(org.activemq.message.ConsumerInfo info) throws javax.jms.JMSException
- Checks if this subscription is a duplicate durable subscription of the given consumer info
getSubscriptionEntry
public SubscriberEntry getSubscriptionEntry()
- Lazily creates the persistent entry representation of this subscription
isLocalSubscription
public boolean isLocalSubscription()
|
|||||||||
| Home >> All >> org >> activemq >> [ service overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC