pub enum FieldReading {
Sample(FieldValue),
Held {
value: FieldValue,
within: bool,
},
Absent,
OwnerError,
BeyondRange,
Unnamed,
Unknown(Unknown),
}Expand description
One series field of one record, as a reader reads it (v2 §2.18).
Variants§
Sample(FieldValue)
Included with a value: a sample.
Held
Not included: the value it holds, known by no change since it was
(within false) or within its deadband. No sample.
Absent
No value: included absent, or not_available.
OwnerError
No value: error, the owner’s error.
BeyondRange
No value: out_of_range, beyond the declared range.
Unnamed
No value: a code this revision does not name, an enum’s escape.
Unknown(Unknown)
No value: the field’s state is unknown (core §7.7), with why.
Implementations§
Source§impl FieldReading
impl FieldReading
Sourcepub const fn sample(&self) -> Option<&FieldValue>
pub const fn sample(&self) -> Option<&FieldValue>
The sample’s value, when it is one.
Sourcepub const fn value(&self) -> Option<&FieldValue>
pub const fn value(&self) -> Option<&FieldValue>
The value it shows: a sample’s, or a held one’s. None for every
reading that is no value, which a reader never shows as one, nor as
0.
Trait Implementations§
Source§impl Clone for FieldReading
impl Clone for FieldReading
Source§impl Debug for FieldReading
impl Debug for FieldReading
Source§impl PartialEq for FieldReading
impl PartialEq for FieldReading
impl StructuralPartialEq for FieldReading
Auto Trait Implementations§
impl Forget for FieldReading
impl Freeze for FieldReadingwhere
*const u8 is !null: Freeze,
PhantomData<f64>: Freeze,
PhantomData<u64>: Freeze,
PhantomData<u8>: Freeze,
PhantomData<Value>: Freeze,
*const LeafNode<String, Value> is !null: Freeze,
PhantomData<(Owned, LeafOrInternal)>: Freeze,
PhantomData<Box<(String, Value)>>: Freeze,
impl Move for FieldReading
impl RefUnwindSafe for FieldReading
impl Send for FieldReading
impl Sync for FieldReading
impl Unpin for FieldReading
impl UnsafeUnpin for FieldReadingwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<f64>: UnsafeUnpin,
PhantomData<u64>: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<Value>: UnsafeUnpin,
*const LeafNode<String, Value> is !null: UnsafeUnpin,
PhantomData<(Owned, LeafOrInternal)>: UnsafeUnpin,
PhantomData<Box<(String, Value)>>: UnsafeUnpin,
impl UnwindSafe for FieldReading
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more