Copy

Trait Copy 

Source
pub trait Copy:
    Unpin
    + Send
    + Sync {
    // Required methods
    fn next(
        &mut self,
    ) -> impl Future<Output = Result<Option<usize>, Error>> + MaybeSend;
    fn abort(&mut self) -> impl Future<Output = Result<(), Error>> + MaybeSend;
}
Expand description

Copy is the trait that OpenDAL returns for stateful copy operations.

Required Methods§

Source

fn next( &mut self, ) -> impl Future<Output = Result<Option<usize>, Error>> + MaybeSend

Drive the copy operation forward.

Ok(Some(n)) means the copy operation made progress by n bytes. Ok(None) means the copy operation has completed.

Source

fn abort(&mut self) -> impl Future<Output = Result<(), Error>> + MaybeSend

Abort the pending copy operation.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl Copy for ()

Source§

async fn next(&mut self) -> Result<Option<usize>, Error>

Source§

async fn abort(&mut self) -> Result<(), Error>

Source§

impl<T> Copy for Box<T>
where T: CopyDyn + ?Sized,

Source§

async fn next(&mut self) -> Result<Option<usize>, Error>

Source§

async fn abort(&mut self) -> Result<(), Error>

Implementors§

Source§

impl Copy for OneShotCopier

Source§

impl<C> Copy for BlockCopier<C>
where C: BlockCopy,

Source§

impl<C> Copy for MultipartCopier<C>
where C: MultipartCopy,

Source§

impl<ONE, TWO> Copy for TwoWays<ONE, TWO>
where ONE: Copy, TWO: Copy,