ObjectStore
A flat keyed store with conditional writes.
Functions
funcget(key) -> tuple[bytes, str] | NoneReturn an object's bytes and entity tag, or None when it does not exist.
paramkeystrReturns
tuple[bytes, str] | Nonefuncput(key, data, if_match=None, if_absent=False) -> strWrite an object and return its new entity tag.
paramkeystrObject key.
paramdatabytesIts new content.
paramif_matchstr | None= NoneWrite only while the object still has this entity tag.
paramif_absentbool= FalseWrite only when the object does not exist.
Returns
strfuncdelete(key, if_match=None) -> NoneRemove an object; a missing one is not an error.
paramkeystrparamif_matchstr | None= NoneReturns
Nonefunclist(prefix='') -> dict[str, str]Return the entity tag of every object whose key starts with prefix.
paramprefixstr= ''Returns
dict[str, str]