pub struct BluetoothTransport { /* private fields */ }
Available on crate feature
bluetooth
only.Implementations§
Source§impl BluetoothTransport
impl BluetoothTransport
Sourcepub async fn new() -> Result<Self, WebauthnCError>
pub async fn new() -> Result<Self, WebauthnCError>
Creates a new instance of the Bluetooth Low Energy scanner.
Trait Implementations§
Source§impl Debug for BluetoothTransport
impl Debug for BluetoothTransport
Source§impl<'b> Transport<'b> for BluetoothTransport
impl<'b> Transport<'b> for BluetoothTransport
Source§fn tokens<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<Self::Token>, WebauthnCError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Available on crate feature ctap2
only.
fn tokens<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<Self::Token>, WebauthnCError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
ctap2
only.§Important
tokens()
is unsupported for BluetoothTransport, as BTLE
authenticator connections are very short-lived and timing sensitive.
This method will always return an empty Vec
of devices.
Use watch()
instead.
Source§fn watch<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<BoxStream<'_, TokenEvent<Self::Token>>, WebauthnCError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Available on crate feature ctap2
only.
fn watch<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<BoxStream<'_, TokenEvent<Self::Token>>, WebauthnCError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
ctap2
only.Watches for and connects to nearby Bluetooth Low Energy authenticators.
§Note
Due to the nature of the Bluetooth Low Energy transport, BluetoothTransport immediately emits a TokenEvent::EnumerationComplete event as soon as it starts.
Auto Trait Implementations§
impl Freeze for BluetoothTransport
impl !RefUnwindSafe for BluetoothTransport
impl Send for BluetoothTransport
impl Sync for BluetoothTransport
impl Unpin for BluetoothTransport
impl !UnwindSafe for BluetoothTransport
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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