KVStore
KVStore class representing a key-value object storage engine. This class allows serializing/deserializing huge objects on store.
Functions
__init__
Initialize self. See help(type(self)) for accurate signature.
full_file_path :
str check_before_read
check_before_write
key :
str file_exists
Return type :
bool generate_new_file
Generate a new eloty file in the directory of the kvstore
Return type :
Path get
Return the value for key if key is in the dictionary, else default.
key :
Any default :
Any get_full_path_without_extension
Return type :
str lock
Lock the kv store, it can no longer be modified. If a modification happens, it copies the file before updating the data, To copy the file is uses the _lock_copy_name
_lock_copy_file_path :
str remove
Remove the store
empty @classmethod
Create an new kv store and generate the file name automatically
Return type :
KVStore from_filename @classmethod
file_name :
str Return type :
KVStore get_base_dir @classmethod
Return type :
str get_full_file_path @classmethod
file_name :
str with_extension :
bool - True Return type :
str