@Override public Set<java.util.Map.Entry<K, V>> entrySet() { return entrySet(null); }
@Override public Set<java.util.Map.Entry<K, V>> entrySet() { return entrySet(null); }
@Override public Set<java.util.Map.Entry<K, V>> entrySet(int count) { return entrySet(null, count); }
@Override public Set<java.util.Map.Entry<K, V>> entrySet(int count) { return entrySet(null, count); }
@Override public Set<java.util.Map.Entry<K, V>> entrySet(String keyPattern) { return entrySet(keyPattern, 10); }
@Override public Set<java.util.Map.Entry<K, V>> entrySet(String keyPattern) { return entrySet(keyPattern, 10); }
@Override public int hashCode() { int h = 0; Iterator<Entry<K,V>> i = entrySet().iterator(); while (i.hasNext()) h += i.next().hashCode(); return h; }
@Override public int hashCode() { int h = 0; Iterator<Entry<K,V>> i = entrySet().iterator(); while (i.hasNext()) h += i.next().hashCode(); return h; }
@Override public void preloadCache() { // Best-attempt warmup - just enumerate as an uncached map (super) and // add anything found into the cache. This does not guarantee to find // entries added during the warmUp, but statistically the cache will have // few misses after this process for(Entry<K,V> entry : super.entrySet()) { CacheKey cacheKey = toCacheKey(entry.getKey()); cachePut(cacheKey, entry.getKey(), entry.getValue()); } }
@Override public void preloadCache() { // Best-attempt warmup - just enumerate as an uncached map (super) and // add anything found into the cache. This does not guarantee to find // entries added during the warmUp, but statistically the cache will have // few misses after this process for(Entry<K,V> entry : super.entrySet()) { CacheKey cacheKey = toCacheKey(entry.getKey()); cachePut(cacheKey, entry.getKey(), entry.getValue()); } }
@Override public boolean equals(Object o) { if (o == this) return true; if (!(o instanceof Map)) return false; Map<?,?> m = (Map<?,?>) o; if (m.size() != size()) return false; try { Iterator<Entry<K,V>> i = entrySet().iterator(); while (i.hasNext()) { Entry<K,V> e = i.next(); K key = e.getKey(); V value = e.getValue(); if (value == null) { if (!(m.get(key)==null && m.containsKey(key))) return false; } else { if (!value.equals(m.get(key))) return false; } } } catch (ClassCastException unused) { return false; } catch (NullPointerException unused) { return false; } return true; }
@Override public boolean equals(Object o) { if (o == this) return true; if (!(o instanceof Map)) return false; Map<?,?> m = (Map<?,?>) o; if (m.size() != size()) return false; try { Iterator<Entry<K,V>> i = entrySet().iterator(); while (i.hasNext()) { Entry<K,V> e = i.next(); K key = e.getKey(); V value = e.getValue(); if (value == null) { if (!(m.get(key)==null && m.containsKey(key))) return false; } else { if (!value.equals(m.get(key))) return false; } } } catch (ClassCastException unused) { return false; } catch (NullPointerException unused) { return false; } return true; }
@Override public Set<java.util.Map.Entry<K, V>> entrySet(String keyPattern) { return entrySet(keyPattern, 10); }
@Override public Set<java.util.Map.Entry<K, V>> entrySet() { return entrySet(null); }
@Override public Set<java.util.Map.Entry<K, V>> entrySet(int count) { return entrySet(null, count); }
@Override public int hashCode() { int h = 0; Iterator<Entry<K,V>> i = entrySet().iterator(); while (i.hasNext()) h += i.next().hashCode(); return h; }
@Override public void preloadCache() { // Best-attempt warmup - just enumerate as an uncached map (super) and // add anything found into the cache. This does not guarantee to find // entries added during the warmUp, but statistically the cache will have // few misses after this process for(Entry<K,V> entry : super.entrySet()) { CacheKey cacheKey = toCacheKey(entry.getKey()); cachePut(cacheKey, entry.getKey(), entry.getValue()); } }
@Override public boolean equals(Object o) { if (o == this) return true; if (!(o instanceof Map)) return false; Map<?,?> m = (Map<?,?>) o; if (m.size() != size()) return false; try { Iterator<Entry<K,V>> i = entrySet().iterator(); while (i.hasNext()) { Entry<K,V> e = i.next(); K key = e.getKey(); V value = e.getValue(); if (value == null) { if (!(m.get(key)==null && m.containsKey(key))) return false; } else { if (!value.equals(m.get(key))) return false; } } } catch (ClassCastException unused) { return false; } catch (NullPointerException unused) { return false; } return true; }