org.objectweb.joram.client.jms.admin
Class Subscription

java.lang.Object
  extended by org.objectweb.joram.client.jms.admin.Subscription

public class Subscription
extends java.lang.Object

The Subscription class is a utility class needed to show information about client subscription.

Be careful, contrary to user, queue or topic administration object, the Subscription object is just a data structure; it is initialized by user.getSubscription() methods and no longer keep consistent with the real state of subscription.


Field Summary
private  boolean durable
          True if the subscription is durable.
private  int messageCount
          Number of pending messages for this subscription.
private  java.lang.String name
          Name of the subscription.
private  java.lang.String topicId
          Related topic unique identification.
 
Constructor Summary
Subscription(java.lang.String name, java.lang.String topicId, int messageCount, boolean durable)
          Creates a new Subscription object.
 
Method Summary
 int getMessageCount()
          Returns the number of pending messages.
 java.lang.String getName()
          Returns the subscription's name.
 java.lang.String getTopicId()
          Returns the related topic unique identification.
 boolean isDurable()
          Returns true if the subscription is durable, false otherwise.
 java.lang.String toString()
          Returns a String image of the subscription.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

name

private java.lang.String name
Name of the subscription.


topicId

private java.lang.String topicId
Related topic unique identification.


messageCount

private int messageCount
Number of pending messages for this subscription.


durable

private boolean durable
True if the subscription is durable.

Constructor Detail

Subscription

public Subscription(java.lang.String name,
                    java.lang.String topicId,
                    int messageCount,
                    boolean durable)
Creates a new Subscription object.

Method Detail

getName

public final java.lang.String getName()
Returns the subscription's name.

Returns:
the subscription's name.

getTopicId

public final java.lang.String getTopicId()
Returns the related topic unique identification.

Returns:
the related topic unique identification.

getMessageCount

public final int getMessageCount()
Returns the number of pending messages.

Returns:
the number of pending messages.

isDurable

public final boolean isDurable()
Returns true if the subscription is durable, false otherwise.

Returns:
true if the subscription is durable, false otherwise.

toString

public java.lang.String toString()
Returns a String image of the subscription.

Overrides:
toString in class java.lang.Object


Copyright © 2010 ScalAgent D.T.. All Rights Reserved.