pub trait FromReader {
type Error: From<Error>;
// Required method
fn from_reader<B>(
reader: B,
num_bytes: u64,
) -> impl Future<Output = Result<DecodedFileChunk<Self>, Self::Error>>
where Self: Sized,
B: AsyncReadExt + Unpin;
}
Expand description
Constructs a file client from a reader.
Required Associated Types§
Required Methods§
Sourcefn from_reader<B>(
reader: B,
num_bytes: u64,
) -> impl Future<Output = Result<DecodedFileChunk<Self>, Self::Error>>
fn from_reader<B>( reader: B, num_bytes: u64, ) -> impl Future<Output = Result<DecodedFileChunk<Self>, Self::Error>>
Returns a file client