org.rosuda.ibase
Class Notifier

java.lang.Object
  extended by org.rosuda.ibase.Notifier
Direct Known Subclasses:
Axis, NodeMarker, SCatSequence, SMarker, SVar

public class Notifier
extends java.lang.Object

Notifier - framework to for recursive cycle-free notification messages to dependent classes

Version:
$Id: Notifier.java 454 2003-07-30 23:03:55Z starsoft $

Constructor Summary
Notifier()
           
 
Method Summary
 void addDepend(Dependent c)
          adds a Dependent class to be notified on marking change
 void beginBatch()
          initiates batch mode - in this mode no notifications are made until endBatch() has been called.
 void delDepend(Dependent c)
          removes a Dependent class from the list of classes to be notified on marking change
 void endBatch()
          ends batch mode. if any notification reqests has been made since beginBatch() then the last one will be passed to dependents. otherwise just batch flag is cleared and no notification is sent.
 void NotifyAll(NotifyMsg msg)
          notifies all Dependent classes in the notify list of a change.
 void NotifyAll(NotifyMsg msg, Dependent c)
          notifies all Dependent classes in the notify list of a change, except for the specified class.
 void NotifyAll(NotifyMsg msg, Dependent c, java.util.Vector path)
          general NotifyAll
 void NotifyAll(NotifyMsg msg, java.util.Vector path)
           
 void startCascadedNotifyAll(NotifyMsg msg)
          initiates cascaded notification process. use this method instead of NotifyAll if you want to make sure that also inderect dependents will recieve the notification
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Notifier

public Notifier()
Method Detail

addDepend

public void addDepend(Dependent c)
adds a Dependent class to be notified on marking change

Parameters:
c - class to be added

delDepend

public void delDepend(Dependent c)
removes a Dependent class from the list of classes to be notified on marking change

Parameters:
c - class to be removed

NotifyAll

public void NotifyAll(NotifyMsg msg,
                      Dependent c)
notifies all Dependent classes in the notify list of a change, except for the specified class.

Parameters:
c - class to be excluded from the current notification (used to prevent loops if a notification method wants to notify all others). If set to NULL, all classes in the list will be notified.

NotifyAll

public void NotifyAll(NotifyMsg msg,
                      java.util.Vector path)

startCascadedNotifyAll

public void startCascadedNotifyAll(NotifyMsg msg)
initiates cascaded notification process. use this method instead of NotifyAll if you want to make sure that also inderect dependents will recieve the notification


NotifyAll

public void NotifyAll(NotifyMsg msg,
                      Dependent c,
                      java.util.Vector path)
general NotifyAll


NotifyAll

public void NotifyAll(NotifyMsg msg)
notifies all Dependent classes in the notify list of a change. (Results in calling NotifyAll(org.rosuda.ibase.NotifyMsg, org.rosuda.ibase.Dependent) with NULL parameter


beginBatch

public void beginBatch()
initiates batch mode - in this mode no notifications are made until endBatch() has been called. batch mode begin/end calls may be nested, but only after last endBatch notification is made.


endBatch

public void endBatch()
ends batch mode. if any notification reqests has been made since beginBatch() then the last one will be passed to dependents. otherwise just batch flag is cleared and no notification is sent.