pub trait Formats {
// Required method
fn headers(&self, signature: u16) -> Option<&[u8]>;
}Expand description
Where compact frames find their layouts.
Fill it only from frames you trust at least as much as the compact frames it will serve. A CRC-16 signature is not a MAC: anyone in radio range can send a format frame or a plaintext full frame whose layout collides with a genuine one and re-reads the same data bytes as other records with a matching full-frame CRC. Expanded records are only as trustworthy as the frame their layout came from: for an authenticated or decrypted compact frame, learn layouts from that meter’s decrypted full frames only (004-compact-and-fragments/SR-001).
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".