pub struct MissingNodePlan {
pub required_cids: Vec<Cid>,
pub required_nodes: usize,
pub required_bytes: usize,
pub missing_cids: Vec<Cid>,
pub missing_nodes: usize,
pub missing_bytes: usize,
}Expand description
Dry-run plan for making a destination store able to read one source tree.
required_cids are all node CIDs reachable from the tree root. missing_cids
are the subset not currently present in the destination store. All CIDs are
sorted by raw CID bytes for deterministic transport planning.
Fields§
§required_cids: Vec<Cid>All reachable node CIDs required by the tree.
required_nodes: usizeNumber of reachable nodes required by the tree.
required_bytes: usizeSerialized bytes for all reachable nodes in the source tree.
missing_cids: Vec<Cid>Required node CIDs not present in the destination store.
missing_nodes: usizeNumber of missing destination nodes.
missing_bytes: usizeSerialized bytes for missing nodes as read from the source store.
Implementations§
Source§impl MissingNodePlan
impl MissingNodePlan
Sourcepub fn required_cids(&self) -> &[Cid]
pub fn required_cids(&self) -> &[Cid]
Return all required CIDs in deterministic byte order.
Sourcepub fn missing_cids(&self) -> &[Cid]
pub fn missing_cids(&self) -> &[Cid]
Return missing CIDs in deterministic byte order.
Trait Implementations§
Source§impl Clone for MissingNodePlan
impl Clone for MissingNodePlan
Source§fn clone(&self) -> MissingNodePlan
fn clone(&self) -> MissingNodePlan
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 MissingNodePlan
impl Debug for MissingNodePlan
Source§impl Default for MissingNodePlan
impl Default for MissingNodePlan
Source§fn default() -> MissingNodePlan
fn default() -> MissingNodePlan
Returns the “default value” for a type. Read more
impl Eq for MissingNodePlan
Source§impl PartialEq for MissingNodePlan
impl PartialEq for MissingNodePlan
impl StructuralPartialEq for MissingNodePlan
Auto Trait Implementations§
impl Freeze for MissingNodePlan
impl RefUnwindSafe for MissingNodePlan
impl Send for MissingNodePlan
impl Sync for MissingNodePlan
impl Unpin for MissingNodePlan
impl UnsafeUnpin for MissingNodePlan
impl UnwindSafe for MissingNodePlan
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,
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