org.mmbase.clustering
Class ChangeManager

java.lang.Object
  extended byorg.mmbase.clustering.ChangeManager

public final class ChangeManager
extends Object

This utility class contains the methods for broadcasting/registering changes on nodes. It is available as 'getChangeManager()' from the StorageManagerFactory.

Version:
$Id: ChangeManager.java,v 1.12 2006/03/31 19:09:04 michiel Exp $
Author:
Pierre van Rooden
See Also:
StorageManagerFactory.getChangeManager()

Constructor Summary
ChangeManager()
           
 
Method Summary
 void commit(Map changes)
          Commit all changes stored in a Changes map.
 void commit(MMObjectNode node, String change)
          Commits the change to a node.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ChangeManager

public ChangeManager()
Method Detail

commit

public void commit(Map changes)
Commit all changes stored in a Changes map. Clears the change status of all changed nodes, then broadcasts changes to the nodes' builders.

Parameters:
changes - a map with node/change value pairs

commit

public void commit(MMObjectNode node,
                   String change)
Commits the change to a node. Fires the node change events through the EventManager. Then clears 'changed' state on the node.

Parameters:
node - the node to commit the change of
change - the type of change: "n": new, "c": commit, "d": delete, "r" : relation changed


MMBase build 1.8.1.20060716