Вопрос

In the API of Google Developer there is a trimToSize() Method, that I can't find / use. How do I clear or reduze the size of my LRU Cache ?

Это было полезно?

Решение

public final void evictAll ()

Added in API level 12

Clear the cache, calling entryRemoved(boolean, K, V, V) on each removed entry.

Use this method.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top