pub enum SizeSpec {
Fixed(u32),
Dynamic {
parameter: ParamId,
use_calibrated: bool,
adjustment: Option<LinearAdjustment>,
},
DiscreteLookup(Vec<DiscreteLookup>),
Unsupported {
element: NameId,
},
}Expand description
How a variable-width field’s size is determined.
Variants§
Fixed(u32)
A literal bit count from SizeInBits/FixedValue.
Dynamic
A bit count read from another parameter, per SizeInBits/DynamicValue.
Fields
§
adjustment: Option<LinearAdjustment>Optional slope/intercept conversion, typically bytes to bits.
DiscreteLookup(Vec<DiscreteLookup>)
A bit count chosen by the first matching entry of a DiscreteLookupList.
Unsupported
The size could not be modelled; decoding such a field reports the element below.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Forget for SizeSpec
impl Freeze for SizeSpec
impl Move for SizeSpec
impl RefUnwindSafe for SizeSpec
impl Send for SizeSpec
impl Sync for SizeSpec
impl Unpin for SizeSpec
impl UnsafeUnpin for SizeSpec
impl UnwindSafe for SizeSpec
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