pub struct ReconnectSettings { /* private fields */ }Expand description
Settings that can be updated before reconnecting to a server
Implementations§
Source§impl ReconnectSettings
impl ReconnectSettings
pub fn new() -> Self
Sourcepub fn address<T>(&mut self, address: T) -> &mut Self
pub fn address<T>(&mut self, address: T) -> &mut Self
Sets the URL that will be used when reconnecting to the server
Sourcepub fn auth(&mut self, auth: Value)
pub fn auth(&mut self, auth: Value)
Sets the authentication data that will be send in the opening request
Sourcepub fn opening_header<T: Into<HeaderValue>, K: Into<String>>(
&mut self,
key: K,
val: T,
) -> &mut Self
pub fn opening_header<T: Into<HeaderValue>, K: Into<String>>( &mut self, key: K, val: T, ) -> &mut Self
Adds an http header to a container that is going to completely replace opening headers on reconnect.
If there are no headers set in ReconnectSettings, client will use headers initially set via the builder.
Trait Implementations§
Source§impl Default for ReconnectSettings
impl Default for ReconnectSettings
Source§fn default() -> ReconnectSettings
fn default() -> ReconnectSettings
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ReconnectSettings
impl RefUnwindSafe for ReconnectSettings
impl Send for ReconnectSettings
impl Sync for ReconnectSettings
impl Unpin for ReconnectSettings
impl UnsafeUnpin for ReconnectSettings
impl UnwindSafe for ReconnectSettings
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