## org.hornetq.api.jms.management
Interface DestinationControl

All Known Subinterfaces:
  JMSQueueControl, TopicControl

    public interface DestinationControl

A DestinationControl is used to manage a JMS Destination.

Author:
  Jeff Mesnil

Method Summary
`String` `getAddress()` Returns the HornetQ address corresponding to this destination.
`int` `getDeliveringCount()` Returns the number of messages that this queue is currently delivering to its consumers.
`long` `getMessageCount()` Returns the number of messages currently in this destination.
`long` `getMessagesAdded()` Returns the number of messages added to this queue since it was created.
`String` `getName()` Returns the name of this destination.
`boolean` `isTemporary()` Returns whether this destination is temporary.
`int` `removeMessages(String filter)` Removed all the messages which matches the specified JMS filter from this destination.

Method Detail

### getName

    String getName()

  Returns the name of this destination.

### getAddress

    String getAddress()

  Returns the HornetQ address corresponding to this destination.

### isTemporary

    boolean isTemporary()

  Returns whether this destination is temporary.

### getMessageCount

    long getMessageCount()
                         throws Exception

  Returns the number of messages currently in this destination.

  Throws:
    `Exception`

### getDeliveringCount

    int getDeliveringCount()

  Returns the number of messages that this queue is currently delivering to its consumers.

### getMessagesAdded

    long getMessagesAdded()

  Returns the number of messages added to this queue since it was created.

### removeMessages

    int removeMessages(String filter)
                       throws Exception

  Removed all the messages which matches the specified JMS filter from this destination.
  Using `null` or an empty filter will remove all messages from this destination.

  Returns:
    the number of removed messages
  Throws:
    `Exception`

Copyright © 2009 Red Hat Inc. All Rights Reserved.