pub struct Supplicant<'a> {
pub controller: &'a ClientControllerProxy,
pub state_update_stream: &'a mut ClientStateUpdatesRequestStream,
pub security_type: SecurityType,
pub password: Option<&'a str>,
}
Expand description
A client supplicant.
Provides the client and security components necessary to attempt a connection via Policy.
Fields§
§controller: &'a ClientControllerProxy
§state_update_stream: &'a mut ClientStateUpdatesRequestStream
§security_type: SecurityType
§password: Option<&'a str>
Implementations§
Source§impl<'a> Supplicant<'a>
impl<'a> Supplicant<'a>
Sourcepub fn reborrow(&mut self) -> Supplicant<'_>
pub fn reborrow(&mut self) -> Supplicant<'_>
Clones the supplicant through reborrowing of mutable references.
§Examples
This function can be used for templating.
ⓘ
let mut supplicant = Supplicant { /* ... */ }; // Template.
// ...
// Connect via the template supplicant but with a particular password.
let _ = connect(Supplicant { password: "********", ..supplicant.reborrow() });
Auto Trait Implementations§
impl<'a> Freeze for Supplicant<'a>
impl<'a> !RefUnwindSafe for Supplicant<'a>
impl<'a> Send for Supplicant<'a>
impl<'a> Sync for Supplicant<'a>
impl<'a> Unpin for Supplicant<'a>
impl<'a> !UnwindSafe for Supplicant<'a>
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