Memoize single value in the automatically evicting cache.
Memoize single value in the automatically evicting cache.
Memoized reference which can expire.
Memoized reference which can expire.
(expired? ref)
(memoize-ttl ttl f)
Returns loading cache for the 0-arity function f
. The value is evicted
automatically after ttl
millis.
Returns loading cache for the 0-arity function `f`. The value is evicted automatically after `ttl` millis.
(memoize-with test-fn f)
Returns loading cache for the 0-arity function f
. The value is evicted
automatically using test-fn
.
The test-fn
is a function on cached x which returns 0-arity function
answering if x is expired and should be evicted:
(test-fn x)
-> (fn [] ^Boolean result)
Returns loading cache for the 0-arity function `f`. The value is evicted automatically using `test-fn`. The `test-fn` is a function on cached x which returns 0-arity function answering if x is expired and should be evicted: `(test-fn x)` -> `(fn [] ^Boolean result)`
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close