200201202203204205206207208209210
setTimeAt(entry); setValueAt(entry, value); unsafe.putAddress(currentPtr, entry); } finally { lock.unlockWrite(); } count.incrementAndGet(); return true; }
225226227228229230231232233234235
break; } currentPtr = entry + NEXT_OFFSET; } } finally { lock.unlockWrite(); } destroyEntry(entry); count.decrementAndGet(); return true;
283284285286287288289290291292293
if (create) { return new WritableRecord<K, V>(this, lock, 0, key, currentPtr); } lock.unlockWrite(); return null; } public int entriesToClean() { return getCount() - (int) (getCapacity() * (1.0 - cleanupThreshold));
319320321322323324325326327328329
currentPtr = entry + NEXT_OFFSET; } } } } finally { lock.unlockWrite(); } } count.addAndGet(-expired); expirations.addAndGet(expired);
345346347348349350351352353354355
cleared++; } unsafe.putAddress(currentPtr, 0); } } finally { lock.unlockWrite(); } } count.addAndGet(-cleared); }
405406407408409410411412413414415
if (record.entry != 0) { currentPtr = record.entry + NEXT_OFFSET; } } } finally { lock.unlockWrite(); } } } protected long bucketFor(long hashCode) {
176177178179180181182183184185186
setValueAt(entry, value); unsafe.putAddress(currentPtr, entry); count.incrementAndGet(); } finally { lock.unlockWrite(); } } public boolean putIfAbsent(K key, V value) { long hashCode = hashCode(key);