1. /*
  2. * Copyright 2002 Sun Microsystems, Inc. All rights reserved.
  3. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  4. */
  5. package javax.jms;
  6. /** A <CODE>Queue</CODE> object encapsulates a provider-specific queue name.
  7. * It is the way a client specifies the identity of a queue to JMS API methods.
  8. *
  9. * <P>The actual length of time messages are held by a queue and the
  10. * consequences of resource overflow are not defined by the JMS API.
  11. *
  12. * @version 1.0 - 9 March 1998
  13. * @author Mark Hapner
  14. * @author Rich Burridge
  15. *
  16. * @see QueueSession#createQueue(String)
  17. */
  18. public interface Queue extends Destination {
  19. /** Gets the name of this queue.
  20. *
  21. * <P>Clients that depend upon the name are not portable.
  22. *
  23. * @return the queue name
  24. *
  25. * @exception JMSException if the JMS provider implementation of
  26. * <CODE>Queue</CODE> fails to return the queue
  27. * name due to some internal
  28. * error.
  29. */
  30. String
  31. getQueueName() throws JMSException;
  32. /** Returns a string representation of this object.
  33. *
  34. * @return the provider-specific identity values for this queue
  35. */
  36. String
  37. toString();
  38. }