You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jackrabbit.apache.org by re...@apache.org on 2009/09/17 17:32:48 UTC
svn commit: r816238 - in
/jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi:
lock/LockManagerImpl.java util/ReferenceChangeTracker.java
Author: reschke
Date: Thu Sep 17 15:32:48 2009
New Revision: 816238
URL: http://svn.apache.org/viewvc?rev=816238&view=rev
Log:
JCR-2087: parametrize generic types
Modified:
jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/lock/LockManagerImpl.java
jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/util/ReferenceChangeTracker.java
Modified: jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/lock/LockManagerImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/lock/LockManagerImpl.java?rev=816238&r1=816237&r2=816238&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/lock/LockManagerImpl.java (original)
+++ jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/lock/LockManagerImpl.java Thu Sep 17 15:32:48 2009
@@ -220,7 +220,7 @@
*/
public void removeLockToken(String lt) throws LockException, RepositoryException {
// JSR170 v. 1.0.1 defines that the token of a session-scoped lock may
- // not be moved over to another session. thus removal ist not possible
+ // not be moved over to another session. Thus removal is not possible
// and the lock is always present in the lock map.
Iterator<LockImpl> it = lockMap.values().iterator();
boolean found = false;
@@ -285,7 +285,7 @@
* Note, that this methods does NOT check if the given node state would
* be affected by the lock present on an ancestor state.
* Note, that in certain cases it might not be possible to detect a lock
- * being present due to the fact that the hierarchy might be imcomplete or
+ * being present due to the fact that the hierarchy might be incomplete or
* not even readable completely. For this reason it seem equally reasonable
* to search for jcr:lockIsDeep property only and omitting all kind of
* verification regarding nodetypes present.
@@ -798,7 +798,7 @@
// unless this lock is session-scoped (token is never transfered)
// and the session isn't the owner yet (token already present),
// it could be that this affects this lock and session became
- // lock holder -> releoad info to assert.
+ // lock holder -> reload info to assert.
lockState.reloadLockInfo();
}
}
Modified: jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/util/ReferenceChangeTracker.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/util/ReferenceChangeTracker.java?rev=816238&r1=816237&r2=816238&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/util/ReferenceChangeTracker.java (original)
+++ jackrabbit/trunk/jackrabbit-jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/util/ReferenceChangeTracker.java Thu Sep 17 15:32:48 2009
@@ -27,6 +27,8 @@
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
/**
* Simple helper class that can be used to keep track of uuid mappings
@@ -41,11 +43,11 @@
/**
* mapping <original uuid> to <new uuid> of mix:referenceable nodes
*/
- private final HashMap uuidMap = new HashMap();
+ private final Map<String, String> uuidMap = new HashMap<String, String>();
/**
* list of processed reference properties that might need correction
*/
- private final ArrayList references = new ArrayList();
+ private final List<PropertyState> references = new ArrayList<PropertyState>();
/**
* Creates a new instance.
@@ -91,7 +93,7 @@
try {
String oldValue = oldReference.getString();
if (uuidMap.containsKey(oldValue)) {
- String newValue = uuidMap.get(oldValue).toString();
+ String newValue = uuidMap.get(oldValue);
remapped = factory.create(newValue, PropertyType.REFERENCE);
}
} catch (RepositoryException e) {
@@ -113,7 +115,7 @@
}
}
- public Iterator getReferences() {
+ public Iterator<PropertyState> getReferences() {
return references.iterator();
}
}