Methods Summary |
---|
public void | addSubscription(Subscription s)Adds a new subscription to the list.
if (s != null) {
// System.out.println("*** Adding a new SUBSCRIPTION");
subscriptionVector.addElement(s);
}
|
public Subscription | getMatchingSubscription(Message message)Finds a subscription matching the given response or NOTIFY.
Enumeration en = subscriptionVector.elements();
while (en.hasMoreElements()) {
Subscription s = (Subscription)en.nextElement();
if (s.containsSubscription(message)) {
// System.out.println("*** Matching SUBSCRIPTION found!");
return s;
}
}
// System.out.println("*** Matching SUBSCRIPTION NOT found!");
return null;
|
public boolean | isEmpty()Checks if the subscription list is empty.
return subscriptionVector.isEmpty();
|
public void | removeSubscription(Subscription s)Removes the given subscription from the list.
if (s != null) {
// System.out.println("*** Removing SUBSCRIPTION");
subscriptionVector.removeElement(s);
}
|