pub struct AssetUpdate {
pub trigger: AssetWatchTrigger,
pub raw_trigger: String,
pub location: String,
pub asset_id: String,
pub asset_type: String,
pub asset: Value,
pub current_calibration: Value,
}Expand description
One delivery from AssetWatch::pump.
Fields§
§trigger: AssetWatchTriggerThe semantic trigger; see AssetWatchTrigger.
raw_trigger: StringThe exact string the server published in payload.trigger (or
"initial_sync" / "initial_sync_empty" for the bootstrap
deliveries). Useful when trigger == Other.
location: Stringasset.location from the broadcast — always matches the
location this watcher was constructed for, except for
LocationChanged events where it’s the old location.
asset_id: Stringasset.asset_id. Empty when trigger == InitialSyncEmpty.
asset_type: Stringasset.asset_type. Empty when trigger == InitialSyncEmpty.
asset: ValueThe full asset object from the broadcast — null when the
trigger is InitialSyncEmpty. Custom nameplate fields live at
asset.custom.<name>.
current_calibration: ValueThe asset’s active calibration record (full JSON including
values.scale, values.offset, expires_at, cert_ref).
null when there’s no calibration on record yet.
Trait Implementations§
Source§impl Clone for AssetUpdate
impl Clone for AssetUpdate
Source§fn clone(&self) -> AssetUpdate
fn clone(&self) -> AssetUpdate
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more