Struct kwap_msg::alloc::Opt [−][src]
Expand description
Low-level representation of a freshly parsed CoAP Option
Both requests and responses may include a list of one or more options. For example, the URI in a request is transported in several options, and metadata that would be carried in an HTTP header in HTTP is supplied as options as well.
Option Numbers
This struct just stores data parsed directly from the message on the wire, and does not compute or store the Option Number.
To get Option OptNumbers, you can use the iterator extension EnumerateOptNumbers on a collection of Opts.
alloc / no-alloc
When crate feature alloc is enabled, you can use crate::alloc::Opt, which uses heap allocation
for data storage, or crate::no_alloc::Opt, which instead has a fixed capacity and
uses stack allocation for data storage.
When alloc is disabled, you must use crate::no_alloc::Opt.
Related
Fields
delta: OptDeltaSee OptDelta
value: OptValueSee OptValue
Trait Implementations
This method returns an ordering between self and other values if one exists. Read more
This method tests less than (for self and other) and is used by the < operator. Read more
This method tests less than or equal to (for self and other) and is used by the <=
operator. Read more
This method tests greater than (for self and other) and is used by the > operator. Read more
Auto Trait Implementations
impl RefUnwindSafe for Opt
impl UnwindSafe for Opt
Blanket Implementations
Mutably borrows from an owned value. Read more
