piermesh/docs/Daisy/Store.md

41 lines
965 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<a id="store-daisy-key-value-store"></a>
# Store: Daisy key value store
### *class* Daisy.Store.Store(store: str, path: str, nodeNickname: str, daisyCryptography)
Key value store
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Daisy/Store.py)
#### epehemeral
Memory only records
* **Type:**
dict
#### createEmpty(key: str)
* **Parameters:**
* **key** (*str*)
* **key** Key to create empty record at
#### getRecord(key: str, ephemeral=False)
Get record at key
* **Parameters:**
* **key** (*str*)
* **ephemeral** (*bool*) Whether key is only in memory, used for session cryptography credentials currently
#### update(entry: str, data, recur: bool = True, write=True)
Update given record
* **Parameters:**
* **entry** (*str*) Key to update record of
* **data** Data to update record with
* **recur** (*bool*) Whether to iterate over data
* **write** (*bool*) Whether record is ephemeral