Struct ipfs_embed::Batch
source · [−]pub struct Batch<'a, S>(_);
Expand description
A handle for performing batch operations on an ipfs storage
Implementations
sourceimpl<'a, S: StoreParams> Batch<'a, S>where
S: StoreParams,
Ipld: References<S::Codecs>,
impl<'a, S: StoreParams> Batch<'a, S>where
S: StoreParams,
Ipld: References<S::Codecs>,
pub fn create_temp_pin(&mut self) -> Result<TempPin>
pub fn temp_pin(
&mut self,
temp: &mut TempPin,
iter: impl IntoIterator<Item = Cid> + Send + 'static
) -> Result<()>
pub fn iter(&mut self) -> Result<impl Iterator<Item = Cid>>
pub fn contains(&mut self, cid: &Cid) -> Result<bool>
pub fn get(&mut self, cid: &Cid) -> Result<Option<Vec<u8>>>
pub fn insert(&mut self, block: Block<S>) -> Result<()>
pub fn resolve(&mut self, alias: &[u8]) -> Result<Option<Cid>>
pub fn alias(&mut self, alias: &[u8], cid: Option<&Cid>) -> Result<()>
pub fn aliases(&mut self) -> Result<Vec<(Vec<u8>, Cid)>>
pub fn reverse_alias(&mut self, cid: &Cid) -> Result<Option<HashSet<Vec<u8>>>>
pub fn missing_blocks(&mut self, cid: &Cid) -> Result<Vec<Cid>>
Auto Trait Implementations
impl<'a, S> !RefUnwindSafe for Batch<'a, S>
impl<'a, S> Send for Batch<'a, S>where
S: Send,
impl<'a, S> !Sync for Batch<'a, S>
impl<'a, S> Unpin for Batch<'a, S>where
S: Unpin,
impl<'a, S> !UnwindSafe for Batch<'a, S>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more