pub struct Node {
pub id: String,
pub coll: String,
pub seq: u64,
pub data: Value,
pub prev: Option<String>,
pub caused_by: Vec<String>,
pub ts: f64,
pub valid_from: Option<String>,
pub valid_to: Option<String>,
pub hash: String,
}Expand description
A single versioned document node in the DAG.
Fields§
§id: StringUser-supplied document ID (e.g. “618000”, “abc-token-id”)
coll: StringCollection name (e.g. “blocks”, “itsl_ops”)
seq: u64Monotonic global sequence number assigned at write time
data: ValueThe document payload (arbitrary JSON)
prev: Option<String>BLAKE2b hash of the previous version of this document (version chain)
caused_by: Vec<String>BLAKE2b hashes of nodes that causally led to this write
ts: f64Unix timestamp (seconds since epoch)
valid_from: Option<String>Bi-temporal valid-from (ISO 8601)
valid_to: Option<String>Bi-temporal valid-to (ISO 8601); None = still valid
hash: StringBLAKE2b hash of this node’s encrypted content (set after writing)
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Node
impl<'de> Deserialize<'de> for Node
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Node
impl RefUnwindSafe for Node
impl Send for Node
impl Sync for Node
impl Unpin for Node
impl UnsafeUnpin for Node
impl UnwindSafe for Node
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more