pub struct ChainLink {
pub seq: u64,
pub d: String,
pub f: String,
pub prev: Option<String>,
pub ts: u64,
}Expand description
A single link in a cryptographic chain.
Fields§
§seq: u64Sequence number (1-based)
d: StringBase64 encoded data
f: StringFingerprint of THIS link’s raw data
prev: Option<String>Fingerprint of the PREVIOUS link (None for genesis)
ts: u64Unix timestamp when this link was created
Implementations§
Source§impl ChainLink
impl ChainLink
Sourcepub fn verify_data(&self) -> Result<String, UniversalError>
pub fn verify_data(&self) -> Result<String, UniversalError>
Verify this link’s data integrity
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ChainLink
impl<'de> Deserialize<'de> for ChainLink
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 ChainLink
impl RefUnwindSafe for ChainLink
impl Send for ChainLink
impl Sync for ChainLink
impl Unpin for ChainLink
impl UnsafeUnpin for ChainLink
impl UnwindSafe for ChainLink
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