Struct m_bus_parser::user_data::value_information::ValueInformation
source · pub struct ValueInformation {
pub decimal_offset_exponent: isize,
pub labels: ArrayVec<ValueLabel, 10>,
pub decimal_scale_exponent: isize,
pub units: ArrayVec<Unit, 10>,
}Expand description
This is the most important type of the this file and represents the whole information inside the value information block value(x) = (multiplier * value + offset) * units
Fields§
§decimal_offset_exponent: isize§labels: ArrayVec<ValueLabel, 10>§decimal_scale_exponent: isize§units: ArrayVec<Unit, 10>Trait Implementations§
source§impl Debug for ValueInformation
impl Debug for ValueInformation
source§impl PartialEq for ValueInformation
impl PartialEq for ValueInformation
source§fn eq(&self, other: &ValueInformation) -> bool
fn eq(&self, other: &ValueInformation) -> bool
This method tests for
self and other values to be equal, and is used
by ==.source§impl TryFrom<&ValueInformationBlock> for ValueInformation
impl TryFrom<&ValueInformationBlock> for ValueInformation
§type Error = DataInformationError
type Error = DataInformationError
The type returned in the event of a conversion error.
source§fn try_from(
value_information_block: &ValueInformationBlock,
) -> Result<Self, DataInformationError>
fn try_from( value_information_block: &ValueInformationBlock, ) -> Result<Self, DataInformationError>
Performs the conversion.
impl StructuralPartialEq for ValueInformation
Auto Trait Implementations§
impl Freeze for ValueInformation
impl RefUnwindSafe for ValueInformation
impl Send for ValueInformation
impl Sync for ValueInformation
impl Unpin for ValueInformation
impl UnwindSafe for ValueInformation
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