Maximum size of the cache
Called when attempt to make space in the cache.
Return the size of a a given cache item If items are objects (for example) this might just be: (x) => 1 If items are arrays of ints and the maxSize is in bytes this function might be: (x) => x.length * 4
Attempt to free space in the cache starting with the last accessed element
returns true iff v can be inserted into the cache without violating the size boundary
Lookup the value for key k If the value is in the cache, return it.
the cached value keyed to k or the computed value of v
Insert the value v (keyed by k) into the cache
Lookup the value for key k
Remove k from the cache