You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@abdera.apache.org by ro...@apache.org on 2006/08/07 02:18:12 UTC
svn commit: r429220 - in
/incubator/abdera/java/trunk/client/src/main/java/org/apache/abdera/protocol/cache:
CachedResponseBase.java lru/LRUCache.java
Author: rooneg
Date: Sun Aug 6 17:18:12 2006
New Revision: 429220
URL: http://svn.apache.org/viewvc?rev=429220&view=rev
Log:
Clean up some nits that IDEA was complaining about in the client caching
code.
[ in client/src/main/java/org/apache/abdera/protocol/cache ]
* CachedResponseBase.java: Remove an extraneous semicolon.
* lru/LRUCache.java
Import java.util.Map, not java.util.Map.Entry.
(LRUCache): Refer to Map.Entry instead of just Entry, since LinkedHashMap's
Entry class is protected and IDEA gets confused about which one you're
talking about.
Modified:
incubator/abdera/java/trunk/client/src/main/java/org/apache/abdera/protocol/cache/CachedResponseBase.java
incubator/abdera/java/trunk/client/src/main/java/org/apache/abdera/protocol/cache/lru/LRUCache.java
Modified: incubator/abdera/java/trunk/client/src/main/java/org/apache/abdera/protocol/cache/CachedResponseBase.java
URL: http://svn.apache.org/viewvc/incubator/abdera/java/trunk/client/src/main/java/org/apache/abdera/protocol/cache/CachedResponseBase.java?rev=429220&r1=429219&r2=429220&view=diff
==============================================================================
--- incubator/abdera/java/trunk/client/src/main/java/org/apache/abdera/protocol/cache/CachedResponseBase.java (original)
+++ incubator/abdera/java/trunk/client/src/main/java/org/apache/abdera/protocol/cache/CachedResponseBase.java Sun Aug 6 17:18:12 2006
@@ -25,7 +25,7 @@
extends ResponseBase
implements CachedResponse {
- protected CacheKey key = null;;
+ protected CacheKey key = null;
protected Cache cache = null;
protected long initial_age = -1;
Modified: incubator/abdera/java/trunk/client/src/main/java/org/apache/abdera/protocol/cache/lru/LRUCache.java
URL: http://svn.apache.org/viewvc/incubator/abdera/java/trunk/client/src/main/java/org/apache/abdera/protocol/cache/lru/LRUCache.java?rev=429220&r1=429219&r2=429220&view=diff
==============================================================================
--- incubator/abdera/java/trunk/client/src/main/java/org/apache/abdera/protocol/cache/lru/LRUCache.java (original)
+++ incubator/abdera/java/trunk/client/src/main/java/org/apache/abdera/protocol/cache/lru/LRUCache.java Sun Aug 6 17:18:12 2006
@@ -18,7 +18,7 @@
package org.apache.abdera.protocol.cache.lru;
import java.util.LinkedHashMap;
-import java.util.Map.Entry;
+import java.util.Map;
import org.apache.abdera.protocol.cache.Cache;
import org.apache.abdera.protocol.cache.CacheKey;
@@ -40,9 +40,10 @@
setMap(
new LinkedHashMap<CacheKey,CachedResponse>(size,0.75f,true) {
@Override
- protected boolean removeEldestEntry(
- Entry<CacheKey, CachedResponse> eldest) {
- return size() > size;
+ protected boolean removeEldestEntry(Map.Entry<CacheKey,
+ CachedResponse> eldest)
+ {
+ return size() > size;
}
}
);