Constructor.
Obtains the cache item that corresponds to node and updates the access time. If realtime is enabled, time is expected to be equal to or greater than the time stored in node. If disabled and the access time is less, the node will not be updated and null returned.
Adds an item to the cache. If the cache is full, the oldest item will be removed and replaced with the new item.
Creates an item in the cache and sets its create time. If the cache is full, the oldest item is replaced with the new item. (In the case where several items are equally old, the choice of which one to be replaced is made arbitrarily.)
Checks whether an item exists in the cache and returns its create time.
Writes the access times and the number of records with that time to a file, appending to that file.
Makes the GC scan the cache items. Should be called by the subclass constructor if it stores values that contain GC references. This method should be called after the constructor of this class has returned.
Obtains the cache item that corresponds to index. Returns null if index is length or greater.
Gets an item from the cache or creates it if not already existing. If the item was found in the cache, its access time is updated, otherwise its create time is set.
Gets an item from the cache. If the item was found in the cache, its access time is updated.
Obtains the cache item that corresponds to node and updates the access time. If realtime is enabled and key could be found, time is expected to be at least the time value stored in node. If disabled and access_time is less, the result is the same as if key could not be found.
Obtains the key of the cache item corresponding to index.
Called when a cache element is removed, replaces the cache items at index "replaced" with the one at index "replace" by swapping the items.
Mixin the type definition for the values.
Cached item struct, storing a key and value.
size of a data item. If 0 is specified (the default), the items stored in the cache are of variable (dynamic) size
if true, each cache item is stored with its create time, in addition to its last access time
Data cache class template. Stores items of raw data, either of fixed or dynamic size.