#[repr(i32)]pub enum PerfClock {
UnknownPerfClock = 0,
Realtime = 1,
Monotonic = 2,
MonotonicRaw = 3,
Boottime = 4,
}
Expand description
Subset of clocks that is supported by perf timestamping. CLOCK_TAI is excluded since it’s not expected to be used in practice, but would require additions to the trace clock synchronisation logic.
Variants§
Implementations§
Source§impl PerfClock
impl PerfClock
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 Ord for PerfClock
impl Ord for PerfClock
Source§impl PartialOrd for PerfClock
impl PartialOrd for PerfClock
impl Copy for PerfClock
impl Eq for PerfClock
impl StructuralPartialEq for PerfClock
Auto Trait Implementations§
impl Freeze for PerfClock
impl RefUnwindSafe for PerfClock
impl Send for PerfClock
impl Sync for PerfClock
impl Unpin for PerfClock
impl UnwindSafe for PerfClock
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