pub struct EventData<'a> {
pub path: EventPath,
pub number: u64,
pub priority: u8,
pub timestamp: EventTimestamp,
pub data: &'a [u8],
}Expand description
EventDataIB (§10.6.9).
§The timestamp is a choice of four, and exactly one is present
§10.6.9’s schema wraps tags 3 to 6 in a one-of, and the two delta forms say so twice
over: “When this tag is present, all other timestamp tags SHALL be omitted.” A record
therefore carries an absolute epoch time, an absolute system time, or a delta against the
previous record in the same report — never two of them, and never none.
The delta forms exist because a burst of events reported together differ by milliseconds: §7.14.1.2 requires a timestamp on every record “at the time it was created (and not when it is reported to a client)”, and encoding forty of them as full 64-bit values is forty times eight octets where a delta is usually one or two.
Fields§
§path: EventPathPath [0].
number: u64EventNumber [1] — §7.14.1.1’s node-scoped number, “monotonically increasing for the
life of the node”, preserved across restarts.
priority: u8Priority [2].
timestamp: EventTimestampThe timestamp, in one of §10.6.9’s four forms.
data: &'a [u8]Data [7] — the encoded TLV element, tag included, exactly as the cluster wrote it.
§10.6.9.3: “If the cluster does not define any payload for the given event instance, this Data field SHALL be encoded as a struct with no member elements” — an empty structure, not an absent field.