#[non_exhaustive]pub enum PortStatus {
Opened,
Disconnected {
kind: ErrorKind,
reason: String,
},
Closed,
}Expand description
A port’s state change in CoreEvent::PortState.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Opened
Disconnected
Lost without close() (unplug, EOF, I/O error); the core has released the port.
Closed
Closed by close() / force_close() / close_all().
Trait Implementations§
Source§impl Clone for PortStatus
impl Clone for PortStatus
Source§impl Debug for PortStatus
impl Debug for PortStatus
impl Eq for PortStatus
Source§impl PartialEq for PortStatus
impl PartialEq for PortStatus
impl StructuralPartialEq for PortStatus
Auto Trait Implementations§
impl Forget for PortStatus
impl Freeze for PortStatus
impl RefUnwindSafe for PortStatus
impl Send for PortStatus
impl Sync for PortStatus
impl Unpin for PortStatus
impl UnsafeUnpin for PortStatus
impl UnwindSafe for PortStatus
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