toad_msg/msg/
ver.rs

1/// Version of the CoAP protocol that the message adheres to.
2///
3/// Right now, this will always be 1, but may support additional values in the future.
4///
5/// See [RFC7252 - Message Details](https://datatracker.ietf.org/doc/html/rfc7252#section-3) for context
6#[derive(Copy, Clone, Hash, PartialEq, PartialOrd, Debug, Eq, Ord)]
7pub struct Version(pub u8);
8
9impl Default for Version {
10  fn default() -> Self {
11    Version(1)
12  }
13}