pub trait WriteImageToAsyncRef<'a>: WriteSupportingVfsAsync {
type WriteImageRefFuture: Future<Output = VfsResult<(), Self>> + Send + Unpin + 'a;
// Required method
fn write_image_async_ref(
self: Pin<&'a Self>,
path: <Self::Path as PathType>::OwnedPath,
image: &'a DynamicImage,
format: ImageFormat,
) -> Self::WriteImageRefFuture;
}Available on crate features
async and image only.Expand description
A trait implemented by async vfs implementations that support writing images from references.
Required Associated Types§
Sourcetype WriteImageRefFuture: Future<Output = VfsResult<(), Self>> + Send + Unpin + 'a
type WriteImageRefFuture: Future<Output = VfsResult<(), Self>> + Send + Unpin + 'a
The future type returned by the write_image_async_ref method.
Required Methods§
Sourcefn write_image_async_ref(
self: Pin<&'a Self>,
path: <Self::Path as PathType>::OwnedPath,
image: &'a DynamicImage,
format: ImageFormat,
) -> Self::WriteImageRefFuture
fn write_image_async_ref( self: Pin<&'a Self>, path: <Self::Path as PathType>::OwnedPath, image: &'a DynamicImage, format: ImageFormat, ) -> Self::WriteImageRefFuture
Writes an image file at the specified path, using the specified image reference and format.
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.
Implementors§
Source§impl<'vfs> WriteImageToAsyncRef<'vfs> for TokioFsVfswhere
'vfs: 'vfs,
Available on crate feature tokio only.
impl<'vfs> WriteImageToAsyncRef<'vfs> for TokioFsVfswhere
'vfs: 'vfs,
Available on crate feature
tokio only.