Hibernate SVN: r20936 - core/branches/Branch_3_3_2_GA_CP/core/src/main/java/org/hibernate/util.
by hibernate-commits@lists.jboss.org
Author: stliu
Date: 2011-05-06 01:42:29 -0400 (Fri, 06 May 2011)
New Revision: 20936
Modified:
core/branches/Branch_3_3_2_GA_CP/core/src/main/java/org/hibernate/util/SoftLimitMRUCache.java
Log:
JBPAPP-6472 hibernate core 3.3.2.GA_CP04 is not compatible with hibernate search before 3.1.1.GA_CP04
Modified: core/branches/Branch_3_3_2_GA_CP/core/src/main/java/org/hibernate/util/SoftLimitMRUCache.java
===================================================================
--- core/branches/Branch_3_3_2_GA_CP/core/src/main/java/org/hibernate/util/SoftLimitMRUCache.java 2011-04-15 22:37:32 UTC (rev 20935)
+++ core/branches/Branch_3_3_2_GA_CP/core/src/main/java/org/hibernate/util/SoftLimitMRUCache.java 2011-05-06 05:42:29 UTC (rev 20936)
@@ -23,8 +23,8 @@
*/
package org.hibernate.util;
+import java.io.IOException;
import java.io.Serializable;
-import java.io.IOException;
import java.lang.ref.ReferenceQueue;
import java.lang.ref.SoftReference;
@@ -58,11 +58,10 @@
* <strong>Note:</strong> This class is serializable, however all entries are
* discarded on serialization.
*
+ * @author Steve Ebersole
+ * @author Manuel Dominguez Sarmiento
* @see org.hibernate.cfg.Environment#QUERY_PLAN_CACHE_MAX_STRONG_REFERENCES
* @see org.hibernate.cfg.Environment#QUERY_PLAN_CACHE_MAX_SOFT_REFERENCES
- *
- * @author Steve Ebersole
- * @author Manuel Dominguez Sarmiento
*/
public class SoftLimitMRUCache implements Serializable {
/**
@@ -93,6 +92,18 @@
}
/**
+ * Constructs a cache with the default settings.
+ *
+ * @see #DEFAULT_STRONG_REF_COUNT
+ * @see #DEFAULT_SOFT_REF_COUNT
+ * @deprecated only for hibernate search to keep compatibility
+ */
+ @Deprecated
+ public SoftLimitMRUCache(int strongRefCount) {
+ this( strongRefCount, DEFAULT_SOFT_REF_COUNT );
+ }
+
+ /**
* Constructs a cache with the specified settings.
*
* @param strongRefCount the strong reference count.
@@ -218,7 +229,7 @@
private static class KeyedSoftReference extends SoftReference {
private final Object key;
- @SuppressWarnings({ "unchecked" })
+ @SuppressWarnings( { "unchecked" })
private KeyedSoftReference(Object key, Object value, ReferenceQueue q) {
super( value, q );
this.key = key;