mirror of
https://github.com/logos-storage/nim-datastore.git
synced 2026-01-07 16:13:07 +00:00
cleanup
This commit is contained in:
parent
76590d4207
commit
c7284b3b6f
@ -8,6 +8,12 @@ import ./types
|
|||||||
|
|
||||||
export databuffer, types, SortOrder
|
export databuffer, types, SortOrder
|
||||||
|
|
||||||
|
## Backend type for Datastores.
|
||||||
|
##
|
||||||
|
## These should be syncrhonous and work with both GC types
|
||||||
|
## and DataBuffer's. This makes it easier to make them threadsafe.
|
||||||
|
##
|
||||||
|
|
||||||
type
|
type
|
||||||
DbQueryResponse*[K, V] = tuple[key: Option[K], data: V]
|
DbQueryResponse*[K, V] = tuple[key: Option[K], data: V]
|
||||||
|
|
||||||
@ -22,6 +28,7 @@ type
|
|||||||
## serialized Key ID, equivalent to `key.id()`
|
## serialized Key ID, equivalent to `key.id()`
|
||||||
data*: DataBuffer
|
data*: DataBuffer
|
||||||
|
|
||||||
|
## Accepted backend key and value types
|
||||||
DbKey* = string | KeyId
|
DbKey* = string | KeyId
|
||||||
DbVal* = seq[byte] | DataBuffer
|
DbVal* = seq[byte] | DataBuffer
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user