Skip to main content

PlatformAsyncDataTransferImpl

Trait PlatformAsyncDataTransferImpl 

Source
pub trait PlatformAsyncDataTransferImpl {
    // Required methods
    fn provide_formats(&self) -> Result<Vec<DataFormat>, ClipboardError>;
    fn provide_items(
        &self,
    ) -> Result<Vec<Rc<dyn IAsyncDataTransferItem>>, ClipboardError>;
    fn dispose(&self, owner: &PlatformAsyncDataTransfer);
}
Expand description

The members a platform backend provides for a PlatformAsyncDataTransfer.

Required Methods§

Source

fn provide_formats(&self) -> Result<Vec<DataFormat>, ClipboardError>

Provides the formats supported by the data transfer. Called until it succeeds: a failure is reported to the caller and not kept.

Source

fn provide_items( &self, ) -> Result<Vec<Rc<dyn IAsyncDataTransferItem>>, ClipboardError>

Provides the items of the data transfer. Called until it succeeds: a failure is reported to the caller and not kept.

Source

fn dispose(&self, owner: &PlatformAsyncDataTransfer)

Releases the platform resources of the data transfer. owner tells whether the formats and the items have been provided.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§