commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t.@apache.org
Subject svn commit: r1775159 - /commons/proper/jcs/trunk/commons-jcs-core/src/main/java/org/apache/commons/jcs/engine/memory/lru/LHMLRUMemoryCache.java
Date Mon, 19 Dec 2016 19:17:17 GMT
Author: tv
Date: Mon Dec 19 19:17:17 2016
New Revision: 1775159

URL: http://svn.apache.org/viewvc?rev=1775159&view=rev
Log:
Remove redundant code

Modified:
    commons/proper/jcs/trunk/commons-jcs-core/src/main/java/org/apache/commons/jcs/engine/memory/lru/LHMLRUMemoryCache.java

Modified: commons/proper/jcs/trunk/commons-jcs-core/src/main/java/org/apache/commons/jcs/engine/memory/lru/LHMLRUMemoryCache.java
URL: http://svn.apache.org/viewvc/commons/proper/jcs/trunk/commons-jcs-core/src/main/java/org/apache/commons/jcs/engine/memory/lru/LHMLRUMemoryCache.java?rev=1775159&r1=1775158&r2=1775159&view=diff
==============================================================================
--- commons/proper/jcs/trunk/commons-jcs-core/src/main/java/org/apache/commons/jcs/engine/memory/lru/LHMLRUMemoryCache.java
(original)
+++ commons/proper/jcs/trunk/commons-jcs-core/src/main/java/org/apache/commons/jcs/engine/memory/lru/LHMLRUMemoryCache.java
Mon Dec 19 19:17:17 2016
@@ -275,7 +275,7 @@ public class LHMLRUMemoryCache<K, V>
     /**
      * Implementation of removeEldestEntry in LinkedHashMap
      */
-    public class LHMSpooler
+    protected class LHMSpooler
         extends java.util.LinkedHashMap<K, MemoryElementDescriptor<K, V>>
     {
         /** Don't change. */
@@ -314,7 +314,8 @@ public class LHMLRUMemoryCache<K, V>
                     log.debug( "LHMLRU max size: " + getCacheAttributes().getMaxObjects()
                         + ".  Spooling element, key: " + element.getKey() );
                 }
-                spoolToDisk( element );
+
+                waterfal( element );
 
                 if ( log.isDebugEnabled() )
                 {
@@ -323,21 +324,5 @@ public class LHMLRUMemoryCache<K, V>
             }
             return true;
         }
-
-        /**
-         * Puts the element in the DiskStore
-         * <p>
-         * @param element The CacheElement
-         */
-        @SuppressWarnings("synthetic-access")
-        private void spoolToDisk( ICacheElement<K, V> element )
-        {
-            getCompositeCache().spoolToDisk( element );
-
-            if ( log.isDebugEnabled() )
-            {
-                log.debug( getCacheName() + "Spooled element to disk: " + element.getKey()
);
-            }
-        }
     }
 }



Mime
View raw message