| 262 | |
| 263 | template <typename KeyType, typename ValueType> |
| 264 | void LruMultiCache<KeyType, ValueType>::EvictOneIfNeeded() { |
| 265 | // SpinLock is locked by the caller public function |
| 266 | lock_.DCheckLocked(); |
| 267 | |
| 268 | if (!lru_list_.empty() && size_ > capacity_) { |
| 269 | EvictOne(lru_list_.back()); |
| 270 | } |
| 271 | } |
| 272 | |
| 273 | template <typename KeyType, typename ValueType> |
| 274 | void LruMultiCache<KeyType, ValueType>::EvictOlderThan( |
nothing calls this directly
no test coverage detected