DataTransferItemExtensions
trait · ferroui-base · v0.5.0
trait DataTransferItemExtensions: IDataTransferItem
Contains extension methods for IDataTransferItem.
Members
contains
fn contains(self: &Self, format: &DataFormat) -> bool
Gets whether the item supports a specific format.
try_get_value
fn try_get_value<T: Clone + 'static>(self: &Self, format: &DataFormatOf<T>) -> Option<T>
Tries to get a value for a given format from the item. Returns
None if the format is not supported.
try_get_text
fn try_get_text(self: &Self) -> Option<String>
Returns a text, if available, from the item.
try_get_bitmap
fn try_get_bitmap(self: &Self) -> Option<Rc<Bitmap>>
Returns a bitmap, if available, from the item.
try_get_file
fn try_get_file(self: &Self) -> Option<Rc<dyn IStorageItem>>
Returns a file (or folder), if available, from the item.
See DataFormat::file.
Trait implementations
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.