Calculates the weights of cache entries. @author Charles Fry @since 11.0
| 23 | * @since 11.0 |
| 24 | */ |
| 25 | @GwtCompatible |
| 26 | @FunctionalInterface |
| 27 | public interface Weigher<K, V> { |
| 28 | |
| 29 | /** |
| 30 | * Returns the weight of a cache entry. There is no unit for entry weights; rather they are simply |
| 31 | * relative to each other. |
| 32 | * |
| 33 | * @return the weight of the entry; must be non-negative |
| 34 | */ |
| 35 | int weigh(K key, V value); |
| 36 | } |
nothing calls this directly
no outgoing calls
no test coverage detected