jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ju...@apache.org
Subject svn commit: r708909 - in /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core: nodetype/virtual/ state/ version/ virtual/
Date Wed, 29 Oct 2008 13:58:51 GMT
Author: jukka
Date: Wed Oct 29 06:58:51 2008
New Revision: 708909

URL: http://svn.apache.org/viewvc?rev=708909&view=rev
Log:
JCR-1775: Transaction-safe versioning

Aggregate virtual node reference updates by using full ChangeLogs instead of individual references.

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/virtual/VirtualNodeTypeStateProvider.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/SharedItemStateManager.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/XAItemStateManager.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/NodeStateEx.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/VersionItemStateManager.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/VersionItemStateProvider.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/XAVersionManager.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/virtual/AbstractVISProvider.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/virtual/VirtualItemStateProvider.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/virtual/VirtualNodeTypeStateProvider.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/virtual/VirtualNodeTypeStateProvider.java?rev=708909&r1=708908&r2=708909&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/virtual/VirtualNodeTypeStateProvider.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/nodetype/virtual/VirtualNodeTypeStateProvider.java
Wed Oct 29 06:58:51 2008
@@ -16,6 +16,14 @@
  */
 package org.apache.jackrabbit.core.nodetype.virtual;
 
+import java.io.UnsupportedEncodingException;
+import java.security.MessageDigest;
+import java.security.NoSuchAlgorithmException;
+
+import javax.jcr.PropertyType;
+import javax.jcr.RepositoryException;
+import javax.jcr.version.OnParentVersionAction;
+
 import org.apache.jackrabbit.core.NodeId;
 import org.apache.jackrabbit.core.nodetype.NodeDef;
 import org.apache.jackrabbit.core.nodetype.NodeDefId;
@@ -23,22 +31,15 @@
 import org.apache.jackrabbit.core.nodetype.NodeTypeRegistry;
 import org.apache.jackrabbit.core.nodetype.PropDef;
 import org.apache.jackrabbit.core.nodetype.ValueConstraint;
+import org.apache.jackrabbit.core.state.ChangeLog;
 import org.apache.jackrabbit.core.state.ItemStateException;
 import org.apache.jackrabbit.core.state.NoSuchItemStateException;
-import org.apache.jackrabbit.core.state.NodeReferences;
 import org.apache.jackrabbit.core.value.InternalValue;
 import org.apache.jackrabbit.core.virtual.AbstractVISProvider;
 import org.apache.jackrabbit.core.virtual.VirtualNodeState;
 import org.apache.jackrabbit.spi.Name;
-import org.apache.jackrabbit.uuid.UUID;
 import org.apache.jackrabbit.spi.commons.name.NameConstants;
-
-import javax.jcr.PropertyType;
-import javax.jcr.RepositoryException;
-import javax.jcr.version.OnParentVersionAction;
-import java.io.UnsupportedEncodingException;
-import java.security.MessageDigest;
-import java.security.NoSuchAlgorithmException;
+import org.apache.jackrabbit.uuid.UUID;
 
 /**
  * This Class implements a virtual item state provider that exposes the
@@ -285,7 +286,7 @@
     /**
      * @inheritDoc
      */
-    public boolean setNodeReferences(NodeReferences refs) {
+    public boolean setNodeReferences(ChangeLog references) {
         return false;
     }
 }

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/SharedItemStateManager.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/SharedItemStateManager.java?rev=708909&r1=708908&r2=708909&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/SharedItemStateManager.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/SharedItemStateManager.java
Wed Oct 29 06:58:51 2008
@@ -16,21 +16,33 @@
  */
 package org.apache.jackrabbit.core.state;
 
+import java.io.PrintStream;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+
+import javax.jcr.PropertyType;
+import javax.jcr.ReferentialIntegrityException;
+import javax.jcr.RepositoryException;
+import javax.jcr.nodetype.ConstraintViolationException;
+import javax.jcr.nodetype.NoSuchNodeTypeException;
+
 import org.apache.jackrabbit.core.ItemId;
 import org.apache.jackrabbit.core.NodeId;
 import org.apache.jackrabbit.core.PropertyId;
 import org.apache.jackrabbit.core.RepositoryImpl;
 import org.apache.jackrabbit.core.cluster.UpdateEventChannel;
-import org.apache.jackrabbit.core.persistence.PersistenceManager;
-import org.apache.jackrabbit.core.persistence.bundle.CachingPersistenceManager;
 import org.apache.jackrabbit.core.nodetype.EffectiveNodeType;
+import org.apache.jackrabbit.core.nodetype.NodeDef;
 import org.apache.jackrabbit.core.nodetype.NodeDefId;
 import org.apache.jackrabbit.core.nodetype.NodeTypeConflictException;
 import org.apache.jackrabbit.core.nodetype.NodeTypeRegistry;
 import org.apache.jackrabbit.core.nodetype.PropDef;
-import org.apache.jackrabbit.core.nodetype.NodeDef;
 import org.apache.jackrabbit.core.observation.EventStateCollection;
 import org.apache.jackrabbit.core.observation.EventStateCollectionFactory;
+import org.apache.jackrabbit.core.persistence.PersistenceManager;
+import org.apache.jackrabbit.core.persistence.bundle.CachingPersistenceManager;
 import org.apache.jackrabbit.core.util.Dumpable;
 import org.apache.jackrabbit.core.value.InternalValue;
 import org.apache.jackrabbit.core.virtual.VirtualItemStateProvider;
@@ -39,18 +51,6 @@
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import javax.jcr.PropertyType;
-import javax.jcr.ReferentialIntegrityException;
-import javax.jcr.RepositoryException;
-import javax.jcr.nodetype.ConstraintViolationException;
-import javax.jcr.nodetype.NoSuchNodeTypeException;
-import java.io.PrintStream;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.Set;
-import java.util.HashMap;
-
 /**
  * Shared <code>ItemStateManager</code> (SISM). Caches objects returned from
a
  * <code>PersistenceManager</code>. Objects returned by this item state
@@ -495,7 +495,7 @@
         /**
          * Virtual node references.
          */
-        private List[] virtualNodeReferences;
+        private ChangeLog[] virtualNodeReferences;
 
         /**
          * Events to dispatch.
@@ -533,7 +533,7 @@
         public void begin() throws ItemStateException, ReferentialIntegrityException {
             shared = new ChangeLog();
 
-            virtualNodeReferences = new List[virtualProviders.length];
+            virtualNodeReferences = new ChangeLog[virtualProviders.length];
 
             /* let listener know about change */
             if (eventChannel != null) {
@@ -660,12 +660,12 @@
                     NodeId id = refs.getId().getTargetId();
                     for (int i = 0; i < virtualProviders.length; i++) {
                         if (virtualProviders[i].hasItemState(id)) {
-                            List virtualRefs = virtualNodeReferences[i];
+                            ChangeLog virtualRefs = virtualNodeReferences[i];
                             if (virtualRefs == null) {
-                                virtualRefs = new LinkedList();
+                                virtualRefs = new ChangeLog();
                                 virtualNodeReferences[i] = virtualRefs;
                             }
-                            virtualRefs.add(refs);
+                            virtualRefs.modified(refs);
                             virtual = true;
                             break;
                         }
@@ -733,12 +733,9 @@
 
                 /* notify virtual providers about node references */
                 for (int i = 0; i < virtualNodeReferences.length; i++) {
-                    List virtualRefs = virtualNodeReferences[i];
+                    ChangeLog virtualRefs = virtualNodeReferences[i];
                     if (virtualRefs != null) {
-                        for (Iterator iter = virtualRefs.iterator(); iter.hasNext();) {
-                            NodeReferences refs = (NodeReferences) iter.next();
-                            virtualProviders[i].setNodeReferences(refs);
-                        }
+                        virtualProviders[i].setNodeReferences(virtualRefs);
                     }
                 }
 

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/XAItemStateManager.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/XAItemStateManager.java?rev=708909&r1=708908&r2=708909&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/XAItemStateManager.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/state/XAItemStateManager.java
Wed Oct 29 06:58:51 2008
@@ -30,6 +30,9 @@
 
 import javax.jcr.ReferentialIntegrityException;
 import javax.jcr.PropertyType;
+
+import java.util.ArrayList;
+import java.util.Collection;
 import java.util.Iterator;
 import java.util.Map;
 import java.util.IdentityHashMap;
@@ -449,6 +452,8 @@
      * @throws ItemStateException if an error occurs
      */
     private void updateVirtualReferences(ChangeLog changes) throws ItemStateException {
+        ChangeLog references = new ChangeLog();
+
         for (Iterator iter = changes.addedStates(); iter.hasNext();) {
             ItemState state = (ItemState) iter.next();
             if (!state.isNode()) {
@@ -458,7 +463,8 @@
                     for (int i = 0; vals != null && i < vals.length; i++) {
                         UUID uuid = vals[i].getUUID();
                         NodeReferencesId refsId = new NodeReferencesId(uuid);
-                        addVirtualReference(prop.getPropertyId(), refsId);
+                        addVirtualReference(
+                                references, prop.getPropertyId(), refsId);
                     }
                 }
             }
@@ -474,7 +480,8 @@
                     for (int i = 0; vals != null && i < vals.length; i++) {
                         UUID uuid = vals[i].getUUID();
                         NodeReferencesId refsId = new NodeReferencesId(uuid);
-                        removeVirtualReference(oldProp.getPropertyId(), refsId);
+                        removeVirtualReference(
+                                references, oldProp.getPropertyId(), refsId);
                     }
                 }
                 if (newProp.getType() == PropertyType.REFERENCE) {
@@ -482,7 +489,8 @@
                     for (int i = 0; vals != null && i < vals.length; i++) {
                         UUID uuid = vals[i].getUUID();
                         NodeReferencesId refsId = new NodeReferencesId(uuid);
-                        addVirtualReference(newProp.getPropertyId(), refsId);
+                        addVirtualReference(
+                                references, newProp.getPropertyId(), refsId);
                     }
                 }
             }
@@ -496,11 +504,14 @@
                     for (int i = 0; vals != null && i < vals.length; i++) {
                         UUID uuid = vals[i].getUUID();
                         NodeReferencesId refsId = new NodeReferencesId(uuid);
-                        removeVirtualReference(prop.getPropertyId(), refsId);
+                        removeVirtualReference(
+                                references, prop.getPropertyId(), refsId);
                     }
                 }
             }
         }
+
+        virtualProvider.setNodeReferences(references);
     }
 
     /**
@@ -510,17 +521,20 @@
      * @param sourceId property id
      * @param refsId node references id
      */
-    private void addVirtualReference(PropertyId sourceId,
-                                     NodeReferencesId refsId)
+    private void addVirtualReference(
+            ChangeLog references, PropertyId sourceId, NodeReferencesId refsId)
             throws NoSuchItemStateException, ItemStateException {
 
-        NodeReferences refs = virtualProvider.getNodeReferences(refsId);
+        NodeReferences refs = references.get(refsId);
+        if (refs == null) {
+            refs = virtualProvider.getNodeReferences(refsId);
+        }
         if (refs == null && virtualProvider.hasItemState(refsId.getTargetId())) {
             refs = new NodeReferences(refsId);
         }
         if (refs != null) {
             refs.addReference(sourceId);
-            virtualProvider.setNodeReferences(refs);
+            references.modified(refs);
         }
     }
 
@@ -531,17 +545,20 @@
      * @param sourceId property id
      * @param refsId node references id
      */
-    private void removeVirtualReference(PropertyId sourceId,
-                                        NodeReferencesId refsId)
+    private void removeVirtualReference(
+            ChangeLog references, PropertyId sourceId, NodeReferencesId refsId)
             throws NoSuchItemStateException, ItemStateException {
 
-        NodeReferences refs = virtualProvider.getNodeReferences(refsId);
+        NodeReferences refs = references.get(refsId);
+        if (refs == null) {
+            refs = virtualProvider.getNodeReferences(refsId);
+        }
         if (refs == null && virtualProvider.hasItemState(refsId.getTargetId())) {
             refs = new NodeReferences(refsId);
         }
         if (refs != null) {
             refs.removeReference(sourceId);
-            virtualProvider.setNodeReferences(refs);
+            references.modified(refs);
         }
     }
 }

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/NodeStateEx.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/NodeStateEx.java?rev=708909&r1=708908&r2=708909&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/NodeStateEx.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/NodeStateEx.java
Wed Oct 29 06:58:51 2008
@@ -35,7 +35,6 @@
 import org.apache.jackrabbit.uuid.UUID;
 import org.apache.jackrabbit.spi.commons.name.NameConstants;
 
-import java.util.HashSet;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Set;

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/VersionItemStateManager.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/VersionItemStateManager.java?rev=708909&r1=708908&r2=708909&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/VersionItemStateManager.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/VersionItemStateManager.java
Wed Oct 29 06:58:51 2008
@@ -16,21 +16,22 @@
  */
 package org.apache.jackrabbit.core.version;
 
-import org.apache.jackrabbit.core.state.SharedItemStateManager;
-import org.apache.jackrabbit.core.state.ItemStateCacheFactory;
-import org.apache.jackrabbit.core.state.ItemStateException;
-import org.apache.jackrabbit.core.state.ChangeLog;
-import org.apache.jackrabbit.core.state.NodeReferences;
-import org.apache.jackrabbit.core.state.ISMLocking;
-import org.apache.jackrabbit.core.persistence.PersistenceManager;
+import java.util.Iterator;
+
+import javax.jcr.ReferentialIntegrityException;
+
 import org.apache.jackrabbit.core.NodeId;
 import org.apache.jackrabbit.core.PropertyId;
 import org.apache.jackrabbit.core.nodetype.NodeTypeRegistry;
-import org.slf4j.LoggerFactory;
+import org.apache.jackrabbit.core.persistence.PersistenceManager;
+import org.apache.jackrabbit.core.state.ChangeLog;
+import org.apache.jackrabbit.core.state.ISMLocking;
+import org.apache.jackrabbit.core.state.ItemStateCacheFactory;
+import org.apache.jackrabbit.core.state.ItemStateException;
+import org.apache.jackrabbit.core.state.NodeReferences;
+import org.apache.jackrabbit.core.state.SharedItemStateManager;
 import org.slf4j.Logger;
-
-import javax.jcr.ReferentialIntegrityException;
-import java.util.Iterator;
+import org.slf4j.LoggerFactory;
 
 /**
  * Spezialized SharedItemStateManager that filters out NodeReferences to
@@ -63,21 +64,28 @@
      * @param references
      * @return
      */
-    public boolean setNodeReferences(NodeReferences references) {
+    public boolean setNodeReferences(ChangeLog references) {
         try {
-            // filter out version storage intern ones
-            NodeReferences refs = new NodeReferences(references.getId());
-            Iterator iter = references.getReferences().iterator();
-            while (iter.hasNext()) {
-                PropertyId id = (PropertyId) iter.next();
-                if (!hasItemState(id.getParentId())) {
-                    refs.addReference(id);
+            ChangeLog log = new ChangeLog();
+
+            Iterator iterator = references.modifiedRefs();
+            while (iterator.hasNext()) {
+                // filter out version storage intern ones
+                NodeReferences source = (NodeReferences) iterator.next();
+                NodeReferences target = new NodeReferences(source.getId());
+                Iterator iter = source.getReferences().iterator();
+                while (iter.hasNext()) {
+                    PropertyId id = (PropertyId) iter.next();
+                    if (!hasItemState(id.getParentId())) {
+                        target.addReference(id);
+                    }
                 }
+                log.modified(target);
             }
 
-            ChangeLog log = new ChangeLog();
-            log.modified(refs);
-            pMgr.store(log);
+            if (log.hasUpdates()) {
+                pMgr.store(log);
+            }
             return true;
         } catch (ItemStateException e) {
             log.error("Error while setting references: " + e.toString());

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/VersionItemStateProvider.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/VersionItemStateProvider.java?rev=708909&r1=708908&r2=708909&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/VersionItemStateProvider.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/VersionItemStateProvider.java
Wed Oct 29 06:58:51 2008
@@ -16,9 +16,12 @@
  */
 package org.apache.jackrabbit.core.version;
 
+import javax.jcr.RepositoryException;
+
 import org.apache.commons.collections.map.ReferenceMap;
 import org.apache.jackrabbit.core.ItemId;
 import org.apache.jackrabbit.core.NodeId;
+import org.apache.jackrabbit.core.state.ChangeLog;
 import org.apache.jackrabbit.core.state.ItemState;
 import org.apache.jackrabbit.core.state.ItemStateException;
 import org.apache.jackrabbit.core.state.ItemStateListener;
@@ -30,8 +33,6 @@
 import org.apache.jackrabbit.core.virtual.VirtualPropertyState;
 import org.apache.jackrabbit.spi.Name;
 
-import javax.jcr.RepositoryException;
-
 /**
  * This Class implements a virtual item state provider.
  */
@@ -115,8 +116,8 @@
     /**
      * @inheritDoc
      */
-    public boolean setNodeReferences(NodeReferences refs) {
-        return stateMgr.setNodeReferences(refs);
+    public boolean setNodeReferences(ChangeLog references) {
+        return stateMgr.setNodeReferences(references);
     }
 
     /**

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/XAVersionManager.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/XAVersionManager.java?rev=708909&r1=708908&r2=708909&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/XAVersionManager.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/version/XAVersionManager.java
Wed Oct 29 06:58:51 2008
@@ -16,6 +16,16 @@
  */
 package org.apache.jackrabbit.core.version;
 
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Map;
+
+import javax.jcr.RepositoryException;
+import javax.jcr.Session;
+import javax.jcr.version.Version;
+import javax.jcr.version.VersionException;
+import javax.jcr.version.VersionHistory;
+
 import org.apache.jackrabbit.core.InternalXAResource;
 import org.apache.jackrabbit.core.ItemId;
 import org.apache.jackrabbit.core.NodeId;
@@ -42,14 +52,6 @@
 import org.apache.jackrabbit.spi.Name;
 import org.apache.jackrabbit.spi.commons.name.NameConstants;
 
-import javax.jcr.RepositoryException;
-import javax.jcr.Session;
-import javax.jcr.version.Version;
-import javax.jcr.version.VersionException;
-import javax.jcr.version.VersionHistory;
-import java.util.HashMap;
-import java.util.Map;
-
 /**
  * Implementation of a {@link VersionManager} that works in an XA environment.
  * Works as a filter between a version manager client and the global version
@@ -242,13 +244,17 @@
     /**
      * {@inheritDoc}
      */
-    public boolean setNodeReferences(NodeReferences refs) {
+    public boolean setNodeReferences(ChangeLog references) {
         ChangeLog changeLog = ((XAItemStateManager) stateMgr).getChangeLog();
         if (changeLog != null) {
-            changeLog.modified(refs);
+            Iterator iterator = references.modifiedRefs();
+            while (iterator.hasNext()) {
+                changeLog.modified((NodeReferences) iterator.next());
+            }
             return true;
+        } else {
+            return false;
         }
-        return false;
     }
 
     /**

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/virtual/AbstractVISProvider.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/virtual/AbstractVISProvider.java?rev=708909&r1=708908&r2=708909&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/virtual/AbstractVISProvider.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/virtual/AbstractVISProvider.java
Wed Oct 29 06:58:51 2008
@@ -42,7 +42,6 @@
 import org.slf4j.LoggerFactory;
 
 import javax.jcr.RepositoryException;
-import java.util.HashSet;
 import java.util.Iterator;
 import java.util.Collection;
 

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/virtual/VirtualItemStateProvider.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/virtual/VirtualItemStateProvider.java?rev=708909&r1=708908&r2=708909&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/virtual/VirtualItemStateProvider.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/virtual/VirtualItemStateProvider.java
Wed Oct 29 06:58:51 2008
@@ -16,15 +16,16 @@
  */
 package org.apache.jackrabbit.core.virtual;
 
+import javax.jcr.RepositoryException;
+
 import org.apache.jackrabbit.core.ItemId;
 import org.apache.jackrabbit.core.NodeId;
+import org.apache.jackrabbit.core.state.ChangeLog;
+import org.apache.jackrabbit.core.state.ItemStateListener;
 import org.apache.jackrabbit.core.state.ItemStateManager;
 import org.apache.jackrabbit.core.state.NodeReferences;
-import org.apache.jackrabbit.core.state.ItemStateListener;
 import org.apache.jackrabbit.spi.Name;
 
-import javax.jcr.RepositoryException;
-
 /**
  * This Interface defines a virtual item state provider.
  */
@@ -75,13 +76,13 @@
         throws RepositoryException;
 
     /**
-     * Informs this provider that the node references to one of its states has
-     * changed.
+     * Informs this provider that the node references to some of its states
+     * have changed.
      *
-     * @param refs
+     * @param references collection of {@link NodeReferences} instances
      * @return <code>true</code> if the reference target is one of its items.
      */
-    boolean setNodeReferences(NodeReferences refs);
+    boolean setNodeReferences(ChangeLog references);
 
 
     /**



Mime
View raw message