pub struct StreamInput { /* private fields */ }Expand description
Builder for network stream inputs
Implementations§
Source§impl StreamInput
impl StreamInput
Sourcepub fn reconnect_delay(self, delay: StdDuration) -> Self
pub fn reconnect_delay(self, delay: StdDuration) -> Self
Set reconnection delay
Sourcepub fn reconnect_attempts(self, attempts: u32) -> Self
pub fn reconnect_attempts(self, attempts: u32) -> Self
Set maximum reconnection attempts
Sourcepub fn option(self, key: impl Into<String>, value: impl Into<String>) -> Self
pub fn option(self, key: impl Into<String>, value: impl Into<String>) -> Self
Add a protocol option
Sourcepub fn user_agent(self, agent: impl Into<String>) -> Self
pub fn user_agent(self, agent: impl Into<String>) -> Self
Set user agent for HTTP
Sourcepub fn timeout(self, timeout: StdDuration) -> Self
pub fn timeout(self, timeout: StdDuration) -> Self
Set timeout
Sourcepub fn into_input(self) -> Input
pub fn into_input(self) -> Input
Convert to regular Input
Trait Implementations§
Source§impl Clone for StreamInput
impl Clone for StreamInput
Source§fn clone(&self) -> StreamInput
fn clone(&self) -> StreamInput
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for StreamInput
impl RefUnwindSafe for StreamInput
impl Send for StreamInput
impl Sync for StreamInput
impl Unpin for StreamInput
impl UnwindSafe for StreamInput
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