pub enum ThreadTime {
ThreadTimeDeltaUs(i64),
ThreadTimeAbsoluteUs(i64),
}
Expand description
Deprecated. Use |extra_counter_values| and |extra_counter_track_uuids| to encode thread time instead.
CPU time for the current thread (e.g., CLOCK_THREAD_CPUTIME_ID) in microseconds.
Variants§
ThreadTimeDeltaUs(i64)
Delta timestamp value since the last TrackEvent or ThreadDescriptor. To calculate the absolute timestamp value, sum up all delta values of the preceding TrackEvents since the last ThreadDescriptor and add the sum to the |reference_timestamp| in ThreadDescriptor. This value should always be positive.
ThreadTimeAbsoluteUs(i64)
This is a one-off absolute value that does not affect delta timestamp computation in subsequent TrackEvents.
Implementations§
Source§impl ThreadTime
impl ThreadTime
Sourcepub fn merge<B>(
field: &mut Option<ThreadTime>,
tag: u32,
wire_type: WireType,
buf: &mut B,
ctx: DecodeContext,
) -> Result<(), DecodeError>where
B: Buf,
pub fn merge<B>(
field: &mut Option<ThreadTime>,
tag: u32,
wire_type: WireType,
buf: &mut B,
ctx: DecodeContext,
) -> Result<(), DecodeError>where
B: Buf,
Decodes an instance of the message from a buffer, and merges it into self.
Sourcepub fn encoded_len(&self) -> usize
pub fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
Trait Implementations§
Source§impl Clone for ThreadTime
impl Clone for ThreadTime
Source§fn clone(&self) -> ThreadTime
fn clone(&self) -> ThreadTime
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ThreadTime
impl Debug for ThreadTime
Source§impl PartialEq for ThreadTime
impl PartialEq for ThreadTime
impl StructuralPartialEq for ThreadTime
Auto Trait Implementations§
impl Freeze for ThreadTime
impl RefUnwindSafe for ThreadTime
impl Send for ThreadTime
impl Sync for ThreadTime
impl Unpin for ThreadTime
impl UnwindSafe for ThreadTime
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