pub enum SecurityAuthenticator {
Open,
Wep(WepAuthenticator),
Wpa(WpaAuthenticator),
}
Expand description
Credentials and configuration for authenticating using a particular wireless network security protocol.
Variants§
Implementations§
source§impl SecurityAuthenticator
impl SecurityAuthenticator
sourcepub fn into_descriptor(self) -> SecurityDescriptor
pub fn into_descriptor(self) -> SecurityDescriptor
Converts an authenticator into a descriptor with no payload (the unit type ()
). Any
payload (i.e., credentials) are dropped.
pub fn into_wep(self) -> Option<WepAuthenticator>
pub fn into_wpa(self) -> Option<WpaAuthenticator>
sourcepub fn to_credentials(&self) -> Option<BareCredentials>
pub fn to_credentials(&self) -> Option<BareCredentials>
Converts the authenticator to bare credentials, if any.
Returns None
if the authenticator is SecurityAuthenticator::None
, as there are no
corresponding credentials in this case.
pub fn as_wep(&self) -> Option<&WepAuthenticator>
pub fn as_wpa(&self) -> Option<&WpaAuthenticator>
pub fn is_open(&self) -> bool
pub fn is_wep(&self) -> bool
pub fn is_wpa(&self) -> bool
Trait Implementations§
source§impl Clone for SecurityAuthenticator
impl Clone for SecurityAuthenticator
source§fn clone(&self) -> SecurityAuthenticator
fn clone(&self) -> SecurityAuthenticator
Returns a copy 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 moresource§impl Debug for SecurityAuthenticator
impl Debug for SecurityAuthenticator
source§impl From<SecurityAuthenticator> for Authentication
impl From<SecurityAuthenticator> for Authentication
source§fn from(authenticator: SecurityAuthenticator) -> Self
fn from(authenticator: SecurityAuthenticator) -> Self
Converts to this type from the input type.
source§impl From<WepAuthenticator> for SecurityAuthenticator
impl From<WepAuthenticator> for SecurityAuthenticator
source§fn from(authenticator: WepAuthenticator) -> Self
fn from(authenticator: WepAuthenticator) -> Self
Converts to this type from the input type.
source§impl From<Wpa<AuthenticatorData>> for SecurityAuthenticator
impl From<Wpa<AuthenticatorData>> for SecurityAuthenticator
source§fn from(authenticator: WpaAuthenticator) -> Self
fn from(authenticator: WpaAuthenticator) -> Self
Converts to this type from the input type.
source§impl PartialEq for SecurityAuthenticator
impl PartialEq for SecurityAuthenticator
source§fn eq(&self, other: &SecurityAuthenticator) -> bool
fn eq(&self, other: &SecurityAuthenticator) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl TryFrom<Authentication> for SecurityAuthenticator
impl TryFrom<Authentication> for SecurityAuthenticator
Converts an Authentication
FIDL datagram into a SecurityAuthenticator
.
This conversion should be preferred where possible.
§Errors
Returns an error if the Authentication
datagram is invalid, such as specifying contradictory
protocols or encoding incompatible or invalid credentials.
§type Error = SecurityError
type Error = SecurityError
The type returned in the event of a conversion error.
impl Eq for SecurityAuthenticator
impl StructuralPartialEq for SecurityAuthenticator
Auto Trait Implementations§
impl Freeze for SecurityAuthenticator
impl RefUnwindSafe for SecurityAuthenticator
impl Send for SecurityAuthenticator
impl Sync for SecurityAuthenticator
impl Unpin for SecurityAuthenticator
impl UnwindSafe for SecurityAuthenticator
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)