ModeShape Distribution 3.0.0.Beta4

org.modeshape.jcr
Class BackupObserver

java.lang.Object
  extended by org.modeshape.jcr.BackupObserver
All Implemented Interfaces:
ChangeSetListener

@ThreadSafe
public class BackupObserver
extends Object
implements ChangeSetListener

A ChangeSetListener that captures the changes being made in a repository, forwarding the node and property changes to the supplied queue, and capturing the set of binary keys that are marked as being used or unused.

See Also:
BackupService

Constructor Summary
protected BackupObserver(Queue<NodeKey> changedNodes)
           
 
Method Summary
 Iterable<BinaryKey> getUnusedBinaryKeys()
          Get the binary keys that have been marked as being unused during the time this observer was listening to the repository.
 Iterable<BinaryKey> getUsedBinaryKeys()
          Get the binary keys that have been marked as being used during the time this observer was listening to the repository.
 void notify(ChangeSet changeSet)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BackupObserver

protected BackupObserver(Queue<NodeKey> changedNodes)
Method Detail

notify

public void notify(ChangeSet changeSet)
Specified by:
notify in interface ChangeSetListener

getUnusedBinaryKeys

public Iterable<BinaryKey> getUnusedBinaryKeys()
Get the binary keys that have been marked as being unused during the time this observer was listening to the repository.

Returns:
the unused binary keys; never null, but possibly empty

getUsedBinaryKeys

public Iterable<BinaryKey> getUsedBinaryKeys()
Get the binary keys that have been marked as being used during the time this observer was listening to the repository.

Returns:
the used binary keys; never null, but possibly empty

ModeShape Distribution 3.0.0.Beta4

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