org.oddjob.jmx.client
Class Synchronizer

java.lang.Object
  extended by org.oddjob.jmx.client.Synchronizer
All Implemented Interfaces:
EventListener, NotificationListener

public class Synchronizer
extends Object
implements NotificationListener

Synchronises asynchronous notifications with a synchronous class to get initial state.

During the synchronisation phase any asynchronous events are queued and processed after synchronisation. Duplicates are detected by the notification number and removed.

Author:
rob

Constructor Summary
Synchronizer(NotificationListener listener)
           
 
Method Summary
 void handleNotification(Notification notification, Object handback)
           
 void synchronize(Notification[] last)
          Synchronous synchronisation with notifications.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Synchronizer

public Synchronizer(NotificationListener listener)
Method Detail

handleNotification

public void handleNotification(Notification notification,
                               Object handback)
Specified by:
handleNotification in interface NotificationListener

synchronize

public void synchronize(Notification[] last)
Synchronous synchronisation with notifications.

Parameters:
last - The last notifications.