This crate provides a generic, fixed-size, N-way associative cache data structure that supports random and least recently used replacement (or your own custom algorithm).
Dive into the documentation for
AssociativeCache to begin.
Constant cache capacity implementations.
An API for get-or-create operations on cache entries, similar to
Various kinds of associativity and
Various iterator implementations and type definitions for
Implementations of various replacement algorithms used when inserting into a full cache.
A fixed-size associative cache mapping
A constant cache capacity.
Given a cache key, return all the slots within the cache where its entry might be.
Given that we need to replace a cache entry when inserting a new one, consider