public interface CapacityLimiter
An instance may be evaluated after every insertion or update operation on the
map or triggered directly with ConcurrentLinkedHashMap.evictWith(CapacityLimiter)
.
An implementation should be aware that the caller's thread will not expect
long execution times or failures as a side effect of the capacity limiter
being evaluated. Execution safety and a fast turn around time should be
considered when implementing this interface.
Modifier and Type | Method and Description |
---|---|
boolean |
hasExceededCapacity(ConcurrentLinkedHashMap<?,?> map)
Determines whether an entry should be evicted from the specified map.
|
boolean hasExceededCapacity(ConcurrentLinkedHashMap<?,?> map)
map
- the map to evaluate for whether an eviction is requiredCopyright © 2019. All rights reserved.