pub enum BridgeEvent {
Transaction(Transaction),
Warning(Warning),
}Expand description
Successful outcome returned by Connection::next.
Inspect the variant to decide how to log or react:
Transaction— normal operation; one full request/response cycle completed.Warning— a non-fatal anomaly was detected and the connection is still running. Log the warning and keep callingnext.
§Examples
ⓘ
match conn.next().await? {
BridgeEvent::Transaction(t) => defmt::info!("ok: {}", t),
BridgeEvent::Warning(w) => defmt::warn!("warn: {}", w),
}Variants§
Transaction(Transaction)
One complete Modbus request/response cycle completed successfully.
Warning(Warning)
A non-fatal protocol anomaly was detected; the connection continues.
See Warning for details on individual anomaly kinds.
Trait Implementations§
Source§impl Debug for BridgeEvent
impl Debug for BridgeEvent
Auto Trait Implementations§
impl Freeze for BridgeEvent
impl RefUnwindSafe for BridgeEvent
impl Send for BridgeEvent
impl Sync for BridgeEvent
impl Unpin for BridgeEvent
impl UnsafeUnpin for BridgeEvent
impl UnwindSafe for BridgeEvent
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