Trait iroh_blobs::util::LivenessTracker
source · pub trait LivenessTracker: Debug + Send + Sync + 'static {
// Required methods
fn on_clone(&self, inner: &HashAndFormat);
fn on_drop(&self, inner: &HashAndFormat);
}
Expand description
A trait for things that can track liveness of blobs and collections.
This trait works together with TempTag to keep track of the liveness of a blob or collection.
It is important to include the format in the liveness tracking, since protecting a collection means protecting the blob and all its children, whereas protecting a raw blob only protects the blob itself.
Required Methods§
sourcefn on_clone(&self, inner: &HashAndFormat)
fn on_clone(&self, inner: &HashAndFormat)
Called on clone
sourcefn on_drop(&self, inner: &HashAndFormat)
fn on_drop(&self, inner: &HashAndFormat)
Called on drop