pub struct RetainedReclaimState {
pub snapshots: BTreeMap<ObjectHash, RetainedStoreSnapshotOwnership>,
pub publications: BTreeMap<ObjectHash, StorePublicationRef>,
pub packages: BTreeMap<ObjectHash, RetainedPackageActivation>,
pub authorizations: BTreeMap<ObjectHash, RetainedReclaimAuthorization>,
}Expand description
Reclamation’s live objects and unfinished accepted authorizations. Receipts release their exact facts; ordinary covered commits are not retained.
Fields§
§snapshots: BTreeMap<ObjectHash, RetainedStoreSnapshotOwnership>§publications: BTreeMap<ObjectHash, StorePublicationRef>§packages: BTreeMap<ObjectHash, RetainedPackageActivation>Implementations§
Source§impl RetainedReclaimState
impl RetainedReclaimState
pub fn genesis() -> Self
pub fn validate(&self) -> Result<(), StoreProtocolError>
pub fn validate_before( &self, successor: &StorePublicationRef, ) -> Result<(), StoreProtocolError>
pub fn include_previous_snapshot( &mut self, accepted: &AcceptedStoreSnapshotRef, metadata: &SnapshotMeta, ) -> Result<(), StoreProtocolError>
Sourcepub fn extend<'a>(
&mut self,
commits: impl IntoIterator<Item = (&'a StoreBatchCommitRef, &'a StoreBatchCommit)>,
) -> Result<(), StoreProtocolError>
pub fn extend<'a>( &mut self, commits: impl IntoIterator<Item = (&'a StoreBatchCommitRef, &'a StoreBatchCommit)>, ) -> Result<(), StoreProtocolError>
Fold the accepted interval as a set of additions and corresponding receipts. Traversal order does not change which exact objects the interval retires.
pub fn retire_receipts<'a>( &mut self, receipts: impl IntoIterator<Item = &'a ReclaimReceiptRef>, ) -> Result<(), StoreProtocolError>
Trait Implementations§
Source§impl Clone for RetainedReclaimState
impl Clone for RetainedReclaimState
Source§fn clone(&self) -> RetainedReclaimState
fn clone(&self) -> RetainedReclaimState
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RetainedReclaimState
impl Debug for RetainedReclaimState
Source§impl<'de> Deserialize<'de> for RetainedReclaimState
impl<'de> Deserialize<'de> for RetainedReclaimState
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
Source§impl PartialEq for RetainedReclaimState
impl PartialEq for RetainedReclaimState
Source§impl Serialize for RetainedReclaimState
impl Serialize for RetainedReclaimState
impl Eq for RetainedReclaimState
impl StructuralPartialEq for RetainedReclaimState
Auto Trait Implementations§
impl Freeze for RetainedReclaimState
impl RefUnwindSafe for RetainedReclaimState
impl Send for RetainedReclaimState
impl Sync for RetainedReclaimState
impl Unpin for RetainedReclaimState
impl UnsafeUnpin for RetainedReclaimState
impl UnwindSafe for RetainedReclaimState
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<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
Checks if this value is equivalent to the given key. Read more
§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
Compare self to
key and return true if they are equal.