pub trait File: Send + DynClone {
// Required methods
fn read<'life0, 'life1, 'async_trait>(
&'life0 mut self,
buf: &'life1 mut [u8],
) -> Pin<Box<dyn Future<Output = IOResult<usize>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn write<'life0, 'life1, 'async_trait>(
&'life0 mut self,
buf: &'life1 [u8],
) -> Pin<Box<dyn Future<Output = IOResult<usize>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn seek<'life0, 'async_trait>(
&'life0 mut self,
pos: FileSize,
) -> Pin<Box<dyn Future<Output = IOResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn tell<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = IOResult<FileSize>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn set_len<'life0, 'async_trait>(
&'life0 mut self,
len: FileSize,
) -> Pin<Box<dyn Future<Output = IOResult<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn metadata<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = IOResult<FileStat>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Required Methods§
fn read<'life0, 'life1, 'async_trait>(
&'life0 mut self,
buf: &'life1 mut [u8],
) -> Pin<Box<dyn Future<Output = IOResult<usize>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn write<'life0, 'life1, 'async_trait>(
&'life0 mut self,
buf: &'life1 [u8],
) -> Pin<Box<dyn Future<Output = IOResult<usize>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn seek<'life0, 'async_trait>(
&'life0 mut self,
pos: FileSize,
) -> Pin<Box<dyn Future<Output = IOResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn tell<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = IOResult<FileSize>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn set_len<'life0, 'async_trait>(
&'life0 mut self,
len: FileSize,
) -> Pin<Box<dyn Future<Output = IOResult<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn metadata<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = IOResult<FileStat>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".