[Java] Interface MemoizeCache<K, V>

Represents a memoize cache with its essential methods

Parameters:
- type of the keys
- type of the values
Authors:
Vaclav Pech

Methods Summary

Methods
Type Params Return Type Name and description
void cleanUpNullReferences()
Invoked when some of the held SoftReferences have been evicted by the garbage collector and so should be removed from the cache.
V get(K key)
V put(K key, V value)

Method Detail

public void cleanUpNullReferences()

Invoked when some of the held SoftReferences have been evicted by the garbage collector and so should be removed from the cache. The implementation must ensure that concurrent invocations of all methods on the cache may occur from other threads and thus should protect any shared resources.

public V get(K key)

public V put(K key, V value)

© 2003-2020 The Apache Software Foundation
Licensed under the Apache license.
https://docs.groovy-lang.org/2.4.21/html/gapi/org/codehaus/groovy/runtime/memoize/MemoizeCache.html