pub struct RetainedReplaySnapshotAuthority {
pub store_root: StoreRootRef,
pub founder_registration: StoreDeviceRegistrationRef,
pub snapshot: StoreSnapshotRef,
pub metadata: SnapshotMeta,
pub snapshot_cut: StoreHistoryCut,
pub accepted_cut: StoreHistoryCut,
pub device_state: ResolvedStoreDeviceState,
pub active_registrations: BTreeMap<StoreDeviceId, ReferencedStoreDeviceRegistration>,
}Expand description
Everything a device needs to install one snapshot as its starting state and verify what arrives after it: the Store root and founder it belongs to, the signed metadata, the cut it covers, and the device state and registrations active at that cut.
Every field is re-derived from the signed metadata by
validate, so an installing device trusts the owner’s
signature over the snapshot and nothing local. What is deliberately absent
is any claim about the other devices having caught up: that is
AcknowledgedStoreSnapshot, and only reclaim needs it. A device installing
a baseline verifies each later commit against the registrations and device
state carried here, exactly as a device that never installed a snapshot
verifies them against its own history.
Fields§
§store_root: StoreRootRef§founder_registration: StoreDeviceRegistrationRef§snapshot: StoreSnapshotRef§metadata: SnapshotMeta§snapshot_cut: StoreHistoryCut§accepted_cut: StoreHistoryCut§device_state: ResolvedStoreDeviceState§active_registrations: BTreeMap<StoreDeviceId, ReferencedStoreDeviceRegistration>Implementations§
Source§impl RetainedReplaySnapshotAuthority
impl RetainedReplaySnapshotAuthority
pub fn validate(&self) -> Result<(), StoreProtocolError>
Trait Implementations§
Source§impl Clone for RetainedReplaySnapshotAuthority
impl Clone for RetainedReplaySnapshotAuthority
Source§fn clone(&self) -> RetainedReplaySnapshotAuthority
fn clone(&self) -> RetainedReplaySnapshotAuthority
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<'de> Deserialize<'de> for RetainedReplaySnapshotAuthority
impl<'de> Deserialize<'de> for RetainedReplaySnapshotAuthority
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>,
Source§impl PartialEq for RetainedReplaySnapshotAuthority
impl PartialEq for RetainedReplaySnapshotAuthority
Source§fn eq(&self, other: &RetainedReplaySnapshotAuthority) -> bool
fn eq(&self, other: &RetainedReplaySnapshotAuthority) -> bool
self and other values to be equal, and is used by ==.impl Eq for RetainedReplaySnapshotAuthority
impl StructuralPartialEq for RetainedReplaySnapshotAuthority
Auto Trait Implementations§
impl !Freeze for RetainedReplaySnapshotAuthority
impl RefUnwindSafe for RetainedReplaySnapshotAuthority
impl Send for RetainedReplaySnapshotAuthority
impl Sync for RetainedReplaySnapshotAuthority
impl Unpin for RetainedReplaySnapshotAuthority
impl UnsafeUnpin for RetainedReplaySnapshotAuthority
impl UnwindSafe for RetainedReplaySnapshotAuthority
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.