org.modeshape.jcr
Class JcrRepository.RepositoryObservationManager

java.lang.Object
  extended by org.modeshape.jcr.JcrRepository.RepositoryObservationManager
All Implemented Interfaces:
Observable, Observer
Enclosing class:
JcrRepository

protected class JcrRepository.RepositoryObservationManager
extends Object
implements Observable, Observer


Constructor Summary
protected JcrRepository.RepositoryObservationManager(Observable repositoryObservable)
           
 
Method Summary
 void notify(Changes changes)
          Method that is called for each set of changes from the Observable instance(s) with which this observer is registered.
 boolean register(Observer observer)
          Register the supplied observer.
 boolean unregister(Observer observer)
          Unregister the supplied observer.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JcrRepository.RepositoryObservationManager

protected JcrRepository.RepositoryObservationManager(Observable repositoryObservable)
Parameters:
repositoryObservable - the repository library observable this observer should register with
Method Detail

notify

public void notify(Changes changes)
Method that is called for each set of changes from the Observable instance(s) with which this observer is registered.

Specified by:
notify in interface Observer
Parameters:
changes - the changes that are being published
See Also:
Observer.notify(org.modeshape.graph.observe.Changes)

register

public boolean register(Observer observer)
Register the supplied observer. This method does nothing if the observer reference is null.

Specified by:
register in interface Observable
Parameters:
observer - the observer to be added; may be null
Returns:
true if the observer was added, or false if the observer was null, if the observer was already registered, or if the observer could not be added
See Also:
Observable.register(org.modeshape.graph.observe.Observer)

unregister

public boolean unregister(Observer observer)
Unregister the supplied observer. This method does nothing if the observer reference is null.

Specified by:
unregister in interface Observable
Parameters:
observer - the observer to be removed; may not be null
Returns:
true if the observer was removed, or false if the observer was null or if the observer was not registered on this source
See Also:
Observable.unregister(org.modeshape.graph.observe.Observer)


Copyright © 2008-2011 JBoss, a division of Red Hat. All Rights Reserved.