More specifically, Vache provides modules implementing caches for values. These caches are parametrised by cache-policies: maximum size, retention, etc.
Note that Vache should not be used to cache resources which may need any form of clean-up (e.g., file-descriptors or network connections). Vache should only be used for values which can be entirely managed by the garbage-collector. If you need resource caches, check-out Rache.
A Mutable structure akin to a hash-table, but with a size bound. Note that, different caches have different policies towards the size bounds: some uphold the bound strictly, some treat the bound as a suggestion. In addition, some caches count their elements somewhat sloppily.
A Mutable structure akin to a set, but with a size bound. Note that, different caches have different policies towards the size bounds: some uphold the bound strictly, some treat the bound as a suggestion. In addition, some caches count their elements somewhat sloppily.
All caches of Vache have either the MAP interface (for key-value stores) or the SET interface (for value stores). Their behavior can be tweaked by the parameters below.
REPLACEMENT_AND_ACCOUNTING is for defining the replacement policy and the accounting policy of a cache. Because of implementation details which are not relevant to go into details here, these two policies are governed by a single, joined parameter.
OVERFLOW is for defining the overflow policy of a cache. Strong means that the cache never holds more element than is specified when calling create. Weak means that the cache may hold more elements than specified when calling create but that supernumerary elements may be collected by the Garbage Collector.