SonicMQ API

progress.message.jclient
Interface MultiDestination

All Superinterfaces:
Destination, javax.naming.Referenceable, java.io.Serializable
All Known Subinterfaces:
MultiTopic

public interface MultiDestination
extends Destination, javax.naming.Referenceable, java.io.Serializable

Description: A MultiDestination is made up of component Destinations. It is used in conjuction with the JMS API to expand operations involving Destinations to include multiple destinations. The precise interpretation of a MultiDestination varies depending on the context in which it is used.

Since:
7.0
Version:
7.0
Author:
Colin MacNaughton
See Also:
Destination, Queue, Topic, MultiTopic

Method Summary
 void add(Destination dest)
          Adds a component destination to the MultiDestination unless it is already a component of the MultiDestination.
 void clear()
          Clears all component Destinations from this MultiDestination.
 boolean contains(Destination dest)
          Returns true if the MultiDestination contains dest.
 boolean equals(java.lang.Object object)
          Tests whether object is a MultiDestination made up of the same component Destinations.
 java.util.Iterator iterator()
          Return a list of the component Destinations that make up this MultiDestination.
 void remove(Destination dest)
          If there is an equivalent component Destination in this MultiDestination it will be removed.
 
Methods inherited from interface javax.naming.Referenceable
getReference
 

Method Detail

add

void add(Destination dest)
         throws JMSException
Adds a component destination to the MultiDestination unless it is already a component of the MultiDestination. If dest is itself a MultiDestination each Destination in dest is added to this MultiDestination.

Parameters:
dest - The destination to add to this MultiDestination
Throws:
JMSException - if the Destination cannot be added.

remove

void remove(Destination dest)
            throws JMSException
If there is an equivalent component Destination in this MultiDestination it will be removed. If dest is itself a MultiDestination each Destination in dest is removed from this MultiDestination.

Parameters:
dest - The component destination to add to this MultiDestination
Throws:
JMSException - If an error occurs removing the destination.

contains

boolean contains(Destination dest)
                 throws JMSException
Returns true if the MultiDestination contains dest. If dest is itself a MultiDestination then this returns true only if this MultiDestination contains all Destinations in dest

Parameters:
dest - The Destination to check.
Returns:
True if this MultiDestination contains all Destinations in dest.
Throws:
JMSException - If there is an error checking for the presence of dest.

iterator

java.util.Iterator iterator()
                            throws JMSException
Return a list of the component Destinations that make up this MultiDestination. Calling remove on the returned Iterator will cause the component Destination to be removed from the Multi destination.

Returns:
An iterator listing the component destinations that make up this Multi destination.
Throws:
JMSException

clear

void clear()
Clears all component Destinations from this MultiDestination.


equals

boolean equals(java.lang.Object object)
Tests whether object is a MultiDestination made up of the same component Destinations.

Overrides:
equals in class java.lang.Object
Parameters:
object - the reference object with which to compare.
Returns:
True if object is also a MultiDestination with the same set of component Destinations

SonicMQ API

Copyright © 1999-2011 Progress Software Corporation. All Rights Reserved.
HTML formatted on 5-August-2011.