pub enum FieldValue {
Uint(u64),
Bool(bool),
Text(String),
Bytes(Vec<u8>),
Array(Vec<FieldValue>),
Map(FieldMap),
}Expand description
One field’s value inside a decoded control message.
Absent optional fields are omitted from their FieldMap rather than
given a zero: a field the wire never carried and a field carrying zero are
different, and only omission can say so.
Variants§
Uint(u64)
A varint or fixed-width integer, widened to u64.
Bool(bool)
A single-bit field.
Text(String)
A field the draft defines as text, or a name for something the draft
leaves opaque — an unknown parameter’s key, rendered 0x21.
Bytes(Vec<u8>)
A field the draft leaves as opaque bytes.
Array(Vec<FieldValue>)
A repeated field, in wire order.
Map(FieldMap)
A nested structure — a location, a parameter set, a fetch’s payload.
Trait Implementations§
Source§impl Clone for FieldValue
impl Clone for FieldValue
Source§fn clone(&self) -> FieldValue
fn clone(&self) -> FieldValue
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FieldValue
impl Debug for FieldValue
impl Eq for FieldValue
Source§impl PartialEq for FieldValue
impl PartialEq for FieldValue
impl StructuralPartialEq for FieldValue
Auto Trait Implementations§
impl Freeze for FieldValue
impl RefUnwindSafe for FieldValue
impl Send for FieldValue
impl Sync for FieldValue
impl Unpin for FieldValue
impl UnsafeUnpin for FieldValue
impl UnwindSafe for FieldValue
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more