Struct qiniu_http::AsyncRequestBody
source · pub struct AsyncRequestBody<'a>(/* private fields */);
Expand description
异步 HTTP 请求体
Implementations§
source§impl<'a> AsyncRequestBody<'a>
impl<'a> AsyncRequestBody<'a>
sourcepub fn from_referenced_reader<T: AsyncRead + AsyncReset + Unpin + Debug + Send + Sync + 'a>(
reader: &'a mut T,
size: u64
) -> Self
pub fn from_referenced_reader<T: AsyncRead + AsyncReset + Unpin + Debug + Send + Sync + 'a>( reader: &'a mut T, size: u64 ) -> Self
通过异步输入流的可变引用创建异步 HTTP 请求体
sourcepub fn from_referenced_bytes(bytes: &'a [u8]) -> Self
pub fn from_referenced_bytes(bytes: &'a [u8]) -> Self
通过二进制数据的引用创建异步 HTTP 请求体
sourcepub fn from_reader(
reader: impl AsyncRead + AsyncReset + Unpin + Debug + Send + Sync + 'static,
size: u64
) -> Self
pub fn from_reader( reader: impl AsyncRead + AsyncReset + Unpin + Debug + Send + Sync + 'static, size: u64 ) -> Self
通过异步输入流创建异步 HTTP 请求体
sourcepub fn from_bytes(bytes: Vec<u8>) -> Self
pub fn from_bytes(bytes: Vec<u8>) -> Self
通过二进制数据创建异步 HTTP 请求体
Trait Implementations§
source§impl AsyncRead for AsyncRequestBody<'_>
impl AsyncRead for AsyncRequestBody<'_>
source§impl AsyncReset for AsyncRequestBody<'_>
impl AsyncReset for AsyncRequestBody<'_>
source§impl<'a> Debug for AsyncRequestBody<'a>
impl<'a> Debug for AsyncRequestBody<'a>
source§impl Default for AsyncRequestBody<'_>
impl Default for AsyncRequestBody<'_>
source§impl<'a> From<&'a [u8]> for AsyncRequestBody<'a>
impl<'a> From<&'a [u8]> for AsyncRequestBody<'a>
source§impl<'a> From<&'a mut AsyncRequestBody<'_>> for AsyncRequestBody<'a>
impl<'a> From<&'a mut AsyncRequestBody<'_>> for AsyncRequestBody<'a>
source§fn from(body: &'a mut AsyncRequestBody<'_>) -> Self
fn from(body: &'a mut AsyncRequestBody<'_>) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a str> for AsyncRequestBody<'a>
impl<'a> From<&'a str> for AsyncRequestBody<'a>
source§impl From<String> for AsyncRequestBody<'_>
impl From<String> for AsyncRequestBody<'_>
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for AsyncRequestBody<'a>
impl<'a> Send for AsyncRequestBody<'a>
impl<'a> Sync for AsyncRequestBody<'a>
impl<'a> Unpin for AsyncRequestBody<'a>
impl<'a> !UnwindSafe for AsyncRequestBody<'a>
Blanket Implementations§
source§impl<R> AsyncReadExt for R
impl<R> AsyncReadExt for R
source§fn read<'a>(&'a mut self, buf: &'a mut [u8]) -> ReadFuture<'a, Self>where
Self: Unpin,
fn read<'a>(&'a mut self, buf: &'a mut [u8]) -> ReadFuture<'a, Self>where
Self: Unpin,
Reads some bytes from the byte stream. Read more
source§fn read_vectored<'a>(
&'a mut self,
bufs: &'a mut [IoSliceMut<'a>]
) -> ReadVectoredFuture<'a, Self>where
Self: Unpin,
fn read_vectored<'a>(
&'a mut self,
bufs: &'a mut [IoSliceMut<'a>]
) -> ReadVectoredFuture<'a, Self>where
Self: Unpin,
source§fn read_to_end<'a>(
&'a mut self,
buf: &'a mut Vec<u8>
) -> ReadToEndFuture<'a, Self>where
Self: Unpin,
fn read_to_end<'a>(
&'a mut self,
buf: &'a mut Vec<u8>
) -> ReadToEndFuture<'a, Self>where
Self: Unpin,
source§fn read_to_string<'a>(
&'a mut self,
buf: &'a mut String
) -> ReadToStringFuture<'a, Self>where
Self: Unpin,
fn read_to_string<'a>(
&'a mut self,
buf: &'a mut String
) -> ReadToStringFuture<'a, Self>where
Self: Unpin,
source§fn read_exact<'a>(&'a mut self, buf: &'a mut [u8]) -> ReadExactFuture<'a, Self>where
Self: Unpin,
fn read_exact<'a>(&'a mut self, buf: &'a mut [u8]) -> ReadExactFuture<'a, Self>where
Self: Unpin,
Reads the exact number of bytes required to fill
buf
. Read moresource§fn take(self, limit: u64) -> Take<Self>where
Self: Sized,
fn take(self, limit: u64) -> Take<Self>where
Self: Sized,
Creates an adapter which will read at most
limit
bytes from it. Read moresource§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more