pub trait RandomReadBlobAsync {
type ReadFuture<'a, 'b>: Future<Output = Result<usize>>
where Self: 'a;
type ReadVecFuture<'a, 'b, 'bb>: Future<Output = Result<usize>>
where Self: 'a,
'bb: 'b;
// Required methods
fn read_async<'a, 'b>(
&'a self,
offs: u64,
buf: &'b mut [MaybeUninit<u8>],
) -> Self::ReadFuture<'a, 'b>;
fn readv_async<'a, 'b, 'bb>(
&'a self,
offs: u64,
iovecs: &'b mut [IoSliceMut<'bb>],
) -> Self::ReadVecFuture<'a, 'b, 'bb>;
// Provided methods
fn read_exact_async<'a, 'b>(
&'a self,
offs: u64,
buf: &'b mut [MaybeUninit<u8>],
) -> impl Future<Output = IOResult<()>> + use<'a, 'b, Self> { ... }
fn readv_all_async<'a, 'b, 'bb>(
&'a self,
offs: u64,
iovecs: &'b mut [IoSliceMut<'bb>],
) -> impl Future<Output = Result<()>> + use<'a, 'b, 'bb, Self> { ... }
fn read_to_end_async<'a>(
&'a self,
offs: u64,
) -> impl Future<Output = IOResult<Vec<u8>>> + use<'a, Self> { ... }
}Expand description
Read-only random accessible Blob operations(asynchronous).
Required Associated Types§
type ReadFuture<'a, 'b>: Future<Output = Result<usize>> where Self: 'a
type ReadVecFuture<'a, 'b, 'bb>: Future<Output = Result<usize>> where Self: 'a, 'bb: 'b
Required Methods§
fn read_async<'a, 'b>( &'a self, offs: u64, buf: &'b mut [MaybeUninit<u8>], ) -> Self::ReadFuture<'a, 'b>
fn readv_async<'a, 'b, 'bb>( &'a self, offs: u64, iovecs: &'b mut [IoSliceMut<'bb>], ) -> Self::ReadVecFuture<'a, 'b, 'bb>
Provided Methods§
fn read_exact_async<'a, 'b>( &'a self, offs: u64, buf: &'b mut [MaybeUninit<u8>], ) -> impl Future<Output = IOResult<()>> + use<'a, 'b, Self>
fn readv_all_async<'a, 'b, 'bb>( &'a self, offs: u64, iovecs: &'b mut [IoSliceMut<'bb>], ) -> impl Future<Output = Result<()>> + use<'a, 'b, 'bb, Self>
fn read_to_end_async<'a>( &'a self, offs: u64, ) -> impl Future<Output = IOResult<Vec<u8>>> + use<'a, Self>
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.