pub enum Event {
DeviceUpdated {
device_id: String,
has_required_attributes: bool,
},
NodeUpdated {
device_id: String,
node_id: String,
has_required_attributes: bool,
},
PropertyUpdated {
device_id: String,
node_id: String,
property_id: String,
has_required_attributes: bool,
},
PropertyValueChanged {
device_id: String,
node_id: String,
property_id: String,
value: String,
fresh: bool,
},
Connected,
}
Expand description
An event from a Homie device, either because of a property change or because something new has been discovered.
Variants§
DeviceUpdated
A new device has been discovered, or an attribute of the device has been updated.
NodeUpdated
An attribute of a node on a device has been updated.
PropertyUpdated
An attribute of a property on a node has been updated.
PropertyValueChanged
The value of a property has changed.
Fields
Connected
Connected to the MQTT broker. This could be either the initial connection or a reconnection after the connection was dropped for some reason.
Trait Implementations§
impl Eq for Event
impl StructuralPartialEq for Event
Auto Trait Implementations§
impl Freeze for Event
impl RefUnwindSafe for Event
impl Send for Event
impl Sync for Event
impl Unpin for Event
impl UnwindSafe for Event
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