#[repr(u32)]pub enum PairingMethod {
    Consent = 1,
    PasskeyDisplay = 2,
    PasskeyComparison = 3,
    PasskeyEntry = 4,
}Expand description
Different types required by the Security Manager for pairing methods. Bluetooth SIG has different requirements for different device capabilities.
Variants§
Consent = 1
The user is asked to accept or reject pairing. This is the minimum method - even when both devices do not support input or output, the delegate will be asked to confirm any pairing not initiated with user intent.
PasskeyDisplay = 2
The user is shown a 6-digit numerical passkey on this device which they must enter on the peer device.
PasskeyComparison = 3
The user is shown a 6-digit numerical passkey on this device which will also shown on the peer device. The user must compare the passkeys and accept the pairing if the passkeys match.
PasskeyEntry = 4
The user is asked to enter a 6-digit passkey on this device which is communicated via the peer device.
Implementations§
Source§impl PairingMethod
 
impl PairingMethod
pub fn from_primitive(prim: u32) -> Option<PairingMethod>
pub const fn into_primitive(self) -> u32
Trait Implementations§
Source§impl Clone for PairingMethod
 
impl Clone for PairingMethod
Source§fn clone(&self) -> PairingMethod
 
fn clone(&self) -> PairingMethod
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 moreSource§impl Debug for PairingMethod
 
impl Debug for PairingMethod
Source§impl<D> Decode<PairingMethod, D> for PairingMethodwhere
    D: ResourceDialect,
 
impl<D> Decode<PairingMethod, D> for PairingMethodwhere
    D: ResourceDialect,
Source§fn new_empty() -> PairingMethod
 
fn new_empty() -> PairingMethod
Creates a valid instance of 
Self. The specific value does not matter,
since it will be overwritten by decode.Source§impl<D> Encode<PairingMethod, D> for PairingMethodwhere
    D: ResourceDialect,
 
impl<D> Encode<PairingMethod, D> for PairingMethodwhere
    D: ResourceDialect,
Source§impl Hash for PairingMethod
 
impl Hash for PairingMethod
Source§impl Ord for PairingMethod
 
impl Ord for PairingMethod
Source§fn cmp(&self, other: &PairingMethod) -> Ordering
 
fn cmp(&self, other: &PairingMethod) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
    Self: Sized,
 
fn max(self, other: Self) -> Selfwhere
    Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for PairingMethod
 
impl PartialEq for PairingMethod
Source§impl PartialOrd for PairingMethod
 
impl PartialOrd for PairingMethod
Source§impl TypeMarker for PairingMethod
 
impl TypeMarker for PairingMethod
Source§type Owned = PairingMethod
 
type Owned = PairingMethod
The owned Rust type which this FIDL type decodes into.
Source§fn inline_align(_context: Context) -> usize
 
fn inline_align(_context: Context) -> usize
Returns the minimum required alignment of the inline portion of the
encoded object. It must be a (nonzero) power of two.
Source§fn inline_size(_context: Context) -> usize
 
fn inline_size(_context: Context) -> usize
Returns the size of the inline portion of the encoded object, including
padding for alignment. Must be a multiple of 
inline_align.Source§fn encode_is_copy() -> bool
 
fn encode_is_copy() -> bool
Returns true if the memory layout of 
Self::Owned matches the FIDL wire
format and encoding requires no validation. When true, we can optimize
encoding arrays and vectors of Self::Owned to a single memcpy. Read moreSource§fn decode_is_copy() -> bool
 
fn decode_is_copy() -> bool
Returns true if the memory layout of 
Self::Owned matches the FIDL wire
format and decoding requires no validation. When true, we can optimize
decoding arrays and vectors of Self::Owned to a single memcpy.Source§impl ValueTypeMarker for PairingMethod
 
impl ValueTypeMarker for PairingMethod
Source§type Borrowed<'a> = PairingMethod
 
type Borrowed<'a> = PairingMethod
The Rust type to use for encoding. This is a particular 
Encode<Self>
type cheaply obtainable from &Self::Owned. There are three cases: Read moreSource§fn borrow(
    value: &<PairingMethod as TypeMarker>::Owned,
) -> <PairingMethod as ValueTypeMarker>::Borrowed<'_>
 
fn borrow( value: &<PairingMethod as TypeMarker>::Owned, ) -> <PairingMethod as ValueTypeMarker>::Borrowed<'_>
Cheaply converts from 
&Self::Owned to Self::Borrowed.impl Copy for PairingMethod
impl Eq for PairingMethod
impl StructuralPartialEq for PairingMethod
Auto Trait Implementations§
impl Freeze for PairingMethod
impl RefUnwindSafe for PairingMethod
impl Send for PairingMethod
impl Sync for PairingMethod
impl Unpin for PairingMethod
impl UnwindSafe for PairingMethod
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