pub struct SampledValue {
pub value: String,
pub context: Option<ReadingContext>,
pub format: Option<ValueFormat>,
pub measurand: Option<Measurand>,
pub phase: Option<Phase>,
pub location: Option<Location>,
pub unit: Option<UnitOfMeasure>,
}
Expand description
Single sampled value in MeterValues. Each value can be accompanied by optional fields.
Fields§
§value: String
Required. Value as a “Raw” (decimal) number or “SignedData”. Field Type is “string” to allow for digitally signed data readings. Decimal numeric values are also acceptable to allow fractional values for measurands such as Temperature and Current.
context: Option<ReadingContext>
Optional. Type of detail value: start, end or sample. Default = “Sample.Periodic”
format: Option<ValueFormat>
Optional. Raw or signed data. Default = “Raw”
measurand: Option<Measurand>
Optional. Type of measurement. Default = “Energy.Active.Import.Register”
phase: Option<Phase>
Optional. indicates how the measured value is to be interpreted. For instance between L1 and neutral (L1-N) Please note that not all values of phase are applicable to all Measurands. When phase is absent, the measured value is interpreted as an overall value.
location: Option<Location>
Optional. Location of measurement. Default=”Outlet”
unit: Option<UnitOfMeasure>
Optional. Unit of the value. Default = “Wh” if the (default) measurand is an “Energy” type.
Trait Implementations§
Source§impl Clone for SampledValue
impl Clone for SampledValue
Source§fn clone(&self) -> SampledValue
fn clone(&self) -> SampledValue
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more