Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
SubscriptionList |
|
| 1.0;1 |
1 | /* | |
2 | * Copyright (C) The Apache Software Foundation. All rights reserved. | |
3 | * | |
4 | * This software is published under the terms of the Apache Software License | |
5 | * version 1.1, a copy of which has been included with this distribution in | |
6 | * the LICENSE file. | |
7 | * | |
8 | * $Id: SubscriptionList.java 155459 2005-02-26 13:24:44Z dirkv $ | |
9 | */ | |
10 | package org.apache.commons.messagelet.model; | |
11 | ||
12 | import java.util.ArrayList; | |
13 | import java.util.List; | |
14 | ||
15 | /** <p><code>SubscriptionList</code> a bean used by the digester to | |
16 | * create a list of JMS subscriptions.</p> | |
17 | * | |
18 | * @author <a href="mailto:jstrachan@apache.org">James Strachan</a> | |
19 | * @version $Revision: 155459 $ | |
20 | */ | |
21 | public class SubscriptionList { | |
22 | ||
23 | 0 | private List subscriptions = new ArrayList(); |
24 | ||
25 | 0 | public SubscriptionList() { |
26 | 0 | } |
27 | ||
28 | /* | |
29 | public void subscribe(JmsConnector connector) throws JMSException { | |
30 | for ( Iterator iter = subscriptions.iterator(); iter.hasNext(); ) { | |
31 | Subscription subscription = (Subscription) iter.next(); | |
32 | subscription.subscribe( connector ); | |
33 | } | |
34 | } | |
35 | */ | |
36 | ||
37 | public void addSubscription(Subscription subscription) { | |
38 | 0 | subscriptions.add( subscription ); |
39 | 0 | } |
40 | ||
41 | public void removeSubscription(Subscription subscription) { | |
42 | 0 | subscriptions.remove( subscription ); |
43 | 0 | } |
44 | ||
45 | public List getSubscriptions() { | |
46 | 0 | return subscriptions; |
47 | } | |
48 | ||
49 | public void setSubscriptions(List subscriptions) { | |
50 | 0 | this.subscriptions = subscriptions; |
51 | 0 | } |
52 | ||
53 | } |