public V remove(Long key) { CacheEntry<Long, V> cacheEntry = map.remove(key); if (cacheEntry != null) { stats.size.decrementAndGet(); return cacheEntry.value; } return null; }
public V remove(Long key) { CacheEntry<Long, V> cacheEntry = map.remove(key); if (cacheEntry != null) { stats.size.decrementAndGet(); return cacheEntry.value; } return null; }
private void evictEntry(Long key) { CacheEntry<Long, V> o = map.remove(key); if (o == null) return; stats.size.decrementAndGet(); stats.evictionCounter.incrementAndGet(); if (evictionListener != null) evictionListener.evictedEntry(o.key, o.value); }
private void evictEntry(Long key) { CacheEntry<Long, V> o = map.remove(key); if (o == null) return; stats.size.decrementAndGet(); stats.evictionCounter.incrementAndGet(); if (evictionListener != null) evictionListener.evictedEntry(o.key, o.value); }
/** Remove {@code o} from the set. * @return <tt>true</tt> if {@code o} was removed to the set, <tt>false</tt> * if {@code o} was not in the set. */ public boolean remove(final long o) { return _map.remove(o) == V; }
@Override public long remove(long address) { Long size = allocatedMemories.remove(address); return size != null ? size : INVALID; }
public boolean remove(long o) { return map.remove(o) != null; }
public boolean remove ( Object k ) { return NonBlockingHashMapLong.this.remove (k) != null; } public IteratorLong iterator() { return new IteratorLong(); }
@Override public void disconnectAddressFromAllocationPath(long address) { allocationPathMap.remove(address); }
public V remove(Long key) { CacheEntry<Long, V> cacheEntry = map.remove(key); if (cacheEntry != null) { stats.size.decrementAndGet(); return cacheEntry.value; } return null; }
public V remove(Long key) { CacheEntry<Long, V> cacheEntry = map.remove(key); if (cacheEntry != null) { stats.size.decrementAndGet(); return cacheEntry.value; } return null; }
void removeLine(long id, CacheLine line, int oldSize) { if (owned.remove(id) == null) shared.remove(id); }
/** Auto-boxing version of {@link #remove(long,Object)}. */ public boolean remove ( Object key, Object Val ) { return (key instanceof Long) ? remove (((Long)key).longValue(), Val) : false; } /** Auto-boxing version of {@link #containsKey(long)}. */
/** Auto-boxing version of {@link #remove(long)}. */ public TypeV remove ( Object key ) { return (key instanceof Long) ? remove (((Long)key).longValue()) : null; } /** Auto-boxing version of {@link #remove(long,Object)}. */
/** Auto-boxing version of {@link #remove(long,Object)}. */ public boolean remove ( Object key, Object Val ) { return (key instanceof Long) ? remove (((Long)key).longValue(), Val) : false; } /** Auto-boxing version of {@link #containsKey(long)}. */
/** Auto-boxing version of {@link #remove(long,Object)}. */ public boolean remove ( Object key, Object Val ) { return (key instanceof Long) ? remove (((Long)key).longValue(), Val) : false; } /** Auto-boxing version of {@link #containsKey(long)}. */
private void evictEntry(Long key) { CacheEntry<Long, V> o = map.remove(key); if (o == null) return; stats.size.decrementAndGet(); stats.evictionCounter.incrementAndGet(); if (evictionListener != null) evictionListener.evictedEntry(o.key, o.value); }
private void evictEntry(Long key) { CacheEntry<Long, V> o = map.remove(key); if (o == null) return; stats.size.decrementAndGet(); stats.evictionCounter.incrementAndGet(); if (evictionListener != null) evictionListener.evictedEntry(o.key, o.value); }
private void removePendingOp(CacheLine line, Op op) { ArrayList<Op> ops = pendingOps.get(op.line); if (ops == null) return; ops.remove(op); if (ops.isEmpty()) pendingOps.remove(op.line); }
/** * Returns and CLEARS the pending messages queue. */ private Set<LineMessage> getAndClearPendingMessages(CacheLine line) { Set<LineMessage> msgs = pendingMessages.remove(line.getId()); if (msgs == null) msgs = Collections.emptySet(); return msgs; }