Liking cljdoc? Tell your friends :D

strojure.memoize-one.expiring-cache

Memoize single value in the automatically evicting cache.

Memoize single value in the automatically evicting cache.
raw docstring

ExpiringRefcljprotocol

Memoized reference which can expire.

Memoized reference which can expire.

expired?clj

(expired? ref)
sourceraw docstring

memoize-ttlclj

(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.
sourceraw docstring

memoize-withclj

(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)`

sourceraw docstring

ttl-test-fnclj

(ttl-test-fn ttl)

TTL millis test-fn.

TTL millis test-fn.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close