pub enum BridgeErrorCode {
NotFound,
Network,
InvalidState,
NotAllowed,
BadMessage,
Unauthorized,
Internal,
}Expand description
Error codes in bridge error messages. The shim maps them to DOMException names.
Variants§
NotFound
No such device (NotFoundError).
Network
The device is disconnected or went away (NetworkError).
InvalidState
The port is not open, or already open (InvalidStateError).
NotAllowed
The device refused, e.g. a read-only NFC card (NotAllowedError).
BadMessage
The message could not be understood.
The token is missing or wrong.
Internal
Anything else.
Trait Implementations§
Source§impl Clone for BridgeErrorCode
impl Clone for BridgeErrorCode
impl Copy for BridgeErrorCode
Source§impl Debug for BridgeErrorCode
impl Debug for BridgeErrorCode
Source§impl<'de> Deserialize<'de> for BridgeErrorCode
impl<'de> Deserialize<'de> for BridgeErrorCode
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for BridgeErrorCode
Source§impl PartialEq for BridgeErrorCode
impl PartialEq for BridgeErrorCode
Source§impl Serialize for BridgeErrorCode
impl Serialize for BridgeErrorCode
impl StructuralPartialEq for BridgeErrorCode
Auto Trait Implementations§
impl Freeze for BridgeErrorCode
impl RefUnwindSafe for BridgeErrorCode
impl Send for BridgeErrorCode
impl Sync for BridgeErrorCode
impl Unpin for BridgeErrorCode
impl UnsafeUnpin for BridgeErrorCode
impl UnwindSafe for BridgeErrorCode
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