Cacher
- class coba.context.Cacher
The interface for a cacher.
Methods
- abstract get_set(key: _K, getter: Callable[[], _V] | _V) ContextManager[_V]
Get a key from the cache.
If the key is not in the cache put it first using getter.
- Parameters:
key – The key to get from the cache.
getter – A method for getting the value if necessary.
- abstract rmv(key: _K) None
Remove a key from the cache.
- Parameters:
key – The key to remove from the cache.