TIBCO Enterprise Message Service

com.tibco.tibjms
Class TibjmsQueue

java.lang.Object
  extended by TibjmsDestination
      extended by com.tibco.tibjms.TibjmsQueue
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, Destination, Queue, javax.naming.Referenceable

public class TibjmsQueue
extends TibjmsDestination
implements Queue, java.io.Serializable, java.lang.Cloneable, javax.naming.Referenceable

Implementation of javax.jms.Queue which can be used for administrative purposes.

Normally JMS applications lookup Queue objects via JNDI calls. This class can be used by the administrator application if it is required to store TibjmsQueue objects in the 3rd party JNDI store such as LDAP or similar.


Constructor Summary
TibjmsQueue()
          Constructs a new TibjmsQueue object.
TibjmsQueue(java.lang.String address)
          Constructs a new TibjmsQueue object with the given address.
TibjmsQueue(java.lang.String address, java.lang.String jndiName)
          Internal constructor.
 
Method Summary
 java.lang.Object clone()
           
 boolean equals(java.lang.Object obj)
           
 java.lang.String getAddress()
          Gets the address of this queue.
 java.lang.String getQueueName()
          Gets the name of this queue.
 javax.naming.Reference getReference()
           
 void setAddress(java.lang.String address)
          Sets the address of this queue.
 java.lang.String toString()
          Returns a string representation of this object.
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TibjmsQueue

public TibjmsQueue()
Constructs a new TibjmsQueue object.


TibjmsQueue

public TibjmsQueue(java.lang.String address)
Constructs a new TibjmsQueue object with the given address.

Parameters:
address - address of the queue

TibjmsQueue

public TibjmsQueue(java.lang.String address,
                   java.lang.String jndiName)
Internal constructor.

Method Detail

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Throws:
java.lang.CloneNotSupportedException

equals

public boolean equals(java.lang.Object obj)

getQueueName

public java.lang.String getQueueName()
                              throws JMSException
Description copied from interface: Queue
Gets the name of this queue.

Clients that depend upon the name are not portable.

Specified by:
getQueueName in interface Queue
Returns:
the queue name
Throws:
JMSException - if the JMS provider implementation of Queue fails to return the queue name due to some internal error.

toString

public java.lang.String toString()
Description copied from interface: Queue
Returns a string representation of this object.

Specified by:
toString in interface Queue
Returns:
the provider-specific identity values for this queue

getReference

public javax.naming.Reference getReference()
                                    throws javax.naming.NamingException
Specified by:
getReference in interface javax.naming.Referenceable
Throws:
javax.naming.NamingException

getAddress

public java.lang.String getAddress()
Gets the address of this queue. Address and name are synonyms.

Returns:
the queue's address

setAddress

public void setAddress(java.lang.String address)
                throws JMSException
Sets the address of this queue. Address and name are synonyms.

Example:

TibjmsQueue queue = new TibjmsQueue();
queue.setAddress("queue.sample");

Parameters:
address - the string representing the address, or name, of this queue
Throws:
JMSException - if the address has already been set

TIBCO Enterprise Message Service

Copyright © TIBCO Software Inc. All rights reserved