#[repr(i32)]pub enum DataPointFlags {
DoNotUse = 0,
NoRecordedValueMask = 1,
}
gen-tonic-messages
and metrics
only.Expand description
DataPointFlags is defined as a protobuf ‘uint32’ type and is to be used as a bit-field representing 32 distinct boolean flags. Each flag defined in this enum is a bit-mask. To test the presence of a single flag in the flags of a data point, for example, use an expression like:
(point.flags & DATA_POINT_FLAGS_NO_RECORDED_VALUE_MASK) == DATA_POINT_FLAGS_NO_RECORDED_VALUE_MASK
Variants§
DoNotUse = 0
The zero value for the enum. Should not be used for comparisons. Instead use bitwise “and” with the appropriate mask as shown above.
NoRecordedValueMask = 1
This DataPoint is valid but has no recorded value. This value SHOULD be used to reflect explicitly missing data in a series, as for an equivalent to the Prometheus “staleness marker”.
Implementations§
Source§impl DataPointFlags
impl DataPointFlags
Sourcepub fn as_str_name(&self) -> &'static str
pub fn as_str_name(&self) -> &'static str
String value of the enum field names used in the ProtoBuf definition.
The values are not transformed in any way and thus are considered stable (if the ProtoBuf definition does not change) and safe for programmatic use.
Sourcepub fn from_str_name(value: &str) -> Option<Self>
pub fn from_str_name(value: &str) -> Option<Self>
Creates an enum from field names used in the ProtoBuf definition.
Trait Implementations§
Source§impl Clone for DataPointFlags
impl Clone for DataPointFlags
Source§fn clone(&self) -> DataPointFlags
fn clone(&self) -> DataPointFlags
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for DataPointFlags
impl Debug for DataPointFlags
Source§impl Default for DataPointFlags
impl Default for DataPointFlags
Source§fn default() -> DataPointFlags
fn default() -> DataPointFlags
Source§impl<'de> Deserialize<'de> for DataPointFlags
impl<'de> Deserialize<'de> for DataPointFlags
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl From<DataPointFlags> for i32
impl From<DataPointFlags> for i32
Source§fn from(value: DataPointFlags) -> i32
fn from(value: DataPointFlags) -> i32
Source§impl Hash for DataPointFlags
impl Hash for DataPointFlags
Source§impl Ord for DataPointFlags
impl Ord for DataPointFlags
Source§fn cmp(&self, other: &DataPointFlags) -> Ordering
fn cmp(&self, other: &DataPointFlags) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for DataPointFlags
impl PartialEq for DataPointFlags
Source§impl PartialOrd for DataPointFlags
impl PartialOrd for DataPointFlags
Source§impl Serialize for DataPointFlags
impl Serialize for DataPointFlags
Source§impl TryFrom<i32> for DataPointFlags
impl TryFrom<i32> for DataPointFlags
Source§type Error = UnknownEnumValue
type Error = UnknownEnumValue
Source§fn try_from(value: i32) -> Result<DataPointFlags, UnknownEnumValue>
fn try_from(value: i32) -> Result<DataPointFlags, UnknownEnumValue>
impl Copy for DataPointFlags
impl Eq for DataPointFlags
impl StructuralPartialEq for DataPointFlags
Auto Trait Implementations§
impl Freeze for DataPointFlags
impl RefUnwindSafe for DataPointFlags
impl Send for DataPointFlags
impl Sync for DataPointFlags
impl Unpin for DataPointFlags
impl UnwindSafe for DataPointFlags
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request