pub struct RequestOptions { /* private fields */ }
Expand description
Parameters for making an HTTP Request. Each of these parameters is currently an optional timeout applicable to the transport layer of the HTTP protocol.
These timeouts are separate from any the user may use to bound a
blocking call to wasi:io/poll.poll
.
Implementations§
Source§impl RequestOptions
impl RequestOptions
Sourcepub fn new() -> RequestOptions
pub fn new() -> RequestOptions
Construct a default request-options
value.
Source§impl RequestOptions
impl RequestOptions
Sourcepub fn connect_timeout(&self) -> Option<u64>
pub fn connect_timeout(&self) -> Option<u64>
The timeout for the initial connect to the HTTP Server.
Source§impl RequestOptions
impl RequestOptions
Sourcepub fn first_byte_timeout(&self) -> Option<u64>
pub fn first_byte_timeout(&self) -> Option<u64>
The timeout for receiving the first byte of the Response body.
Source§impl RequestOptions
impl RequestOptions
Sourcepub fn between_bytes_timeout(&self) -> Option<u64>
pub fn between_bytes_timeout(&self) -> Option<u64>
The timeout for receiving subsequent chunks of bytes in the Response body stream.
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for RequestOptions
impl RefUnwindSafe for RequestOptions
impl Send for RequestOptions
impl Sync for RequestOptions
impl Unpin for RequestOptions
impl UnwindSafe for RequestOptions
Blanket Implementations§
Source§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