dataflake.cache.simple

class dataflake.cache.simple.SimpleCache

Simple instance-level cache

get(key, default=None)

Get value for the given key

If no value is found the default value will be returned.

invalidate(key=None)

Invalidate the given key, or all key/values if no key is passed.

items()

Return all cached keys and values

Returns a sequence of (key, value) tuples.

keys()

Return all cache keys

set(key, value)

Store a key/value pair

values()

Return all cached values

class dataflake.cache.simple.LockingSimpleCache

Simple module-level cache protected by a lock serializing access

get(*args, **kw)

Get value for the given key

If no value is found the default value will be returned.

invalidate(*args, **kw)

Invalidate the given key, or all key/values if no key is passed.

items()

Return all cached keys and values

Returns a sequence of (key, value) tuples.

keys()

Return all cache keys

set(*args, **kw)

Store a key/value pair

values()

Return all cached values

Table Of Contents

Previous topic

Next topic

Related links

This Page


Download as PDF