Struct coins_ledger::transports::Ledger
source · pub struct Ledger(/* private fields */);
Expand description
A Ledger device connection. This wraps the default transport type. In
native code, this is the hidapi
library. When the node
or browser
feature is selected, it is a Ledger JS transport library.
Trait Implementations§
source§impl LedgerAsync for Ledger
impl LedgerAsync for Ledger
source§fn init<'async_trait>(
) -> Pin<Box<dyn Future<Output = Result<Self, LedgerError>> + Send + 'async_trait>>where
Self: 'async_trait,
fn init<'async_trait>(
) -> Pin<Box<dyn Future<Output = Result<Self, LedgerError>> + Send + 'async_trait>>where
Self: 'async_trait,
Init the connection to the device. This may fail if the device is already in use by some
other process.
source§fn exchange<'life0, 'life1, 'async_trait>(
&'life0 self,
packet: &'life1 APDUCommand
) -> Pin<Box<dyn Future<Output = Result<APDUAnswer, LedgerError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn exchange<'life0, 'life1, 'async_trait>(
&'life0 self,
packet: &'life1 APDUCommand
) -> Pin<Box<dyn Future<Output = Result<APDUAnswer, LedgerError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Exchange a packet with the device.
Auto Trait Implementations§
impl !RefUnwindSafe for Ledger
impl Send for Ledger
impl Sync for Ledger
impl Unpin for Ledger
impl !UnwindSafe for Ledger
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