pub struct ThreadDescriptor {
pub pid: Option<i32>,
pub tid: Option<i32>,
pub thread_name: Option<String>,
pub chrome_thread_type: Option<i32>,
pub reference_timestamp_us: Option<i64>,
pub reference_thread_time_us: Option<i64>,
pub reference_thread_instruction_count: Option<i64>,
pub legacy_sort_index: Option<i32>,
}Expand description
Describes a thread’s attributes. Emitted as part of a TrackDescriptor, usually by the thread’s trace writer.
Next id: 9.
Fields§
§pid: Option<i32>§tid: Option<i32>§thread_name: Option<String>§chrome_thread_type: Option<i32>§reference_timestamp_us: Option<i64>Deprecated. Use ClockSnapshot in combination with TracePacket’s timestamp and timestamp_clock_id fields instead.
reference_thread_time_us: Option<i64>Absolute reference values. Clock values in subsequent TrackEvents can be encoded accumulatively and relative to these. This reduces their var-int encoding size. TODO(eseckler): Deprecated. Replace these with ClockSnapshot encoding.
reference_thread_instruction_count: Option<i64>§legacy_sort_index: Option<i32>To support old UI. New UI should determine default sorting by thread_type.
Implementations§
Source§impl ThreadDescriptor
impl ThreadDescriptor
Sourcepub fn legacy_sort_index(&self) -> i32
pub fn legacy_sort_index(&self) -> i32
Returns the value of legacy_sort_index, or the default value if legacy_sort_index is unset.
Sourcepub fn chrome_thread_type(&self) -> ChromeThreadType
pub fn chrome_thread_type(&self) -> ChromeThreadType
Returns the enum value of chrome_thread_type, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn set_chrome_thread_type(&mut self, value: ChromeThreadType)
pub fn set_chrome_thread_type(&mut self, value: ChromeThreadType)
Sets chrome_thread_type to the provided enum value.
Sourcepub fn thread_name(&self) -> &str
pub fn thread_name(&self) -> &str
Returns the value of thread_name, or the default value if thread_name is unset.
Sourcepub fn reference_timestamp_us(&self) -> i64
pub fn reference_timestamp_us(&self) -> i64
Returns the value of reference_timestamp_us, or the default value if reference_timestamp_us is unset.
Sourcepub fn reference_thread_time_us(&self) -> i64
pub fn reference_thread_time_us(&self) -> i64
Returns the value of reference_thread_time_us, or the default value if reference_thread_time_us is unset.
Sourcepub fn reference_thread_instruction_count(&self) -> i64
pub fn reference_thread_instruction_count(&self) -> i64
Returns the value of reference_thread_instruction_count, or the default value if reference_thread_instruction_count is unset.
Trait Implementations§
Source§impl Clone for ThreadDescriptor
impl Clone for ThreadDescriptor
Source§fn clone(&self) -> ThreadDescriptor
fn clone(&self) -> ThreadDescriptor
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ThreadDescriptor
impl Debug for ThreadDescriptor
Source§impl Default for ThreadDescriptor
impl Default for ThreadDescriptor
Source§fn default() -> ThreadDescriptor
fn default() -> ThreadDescriptor
Source§impl Message for ThreadDescriptor
impl Message for ThreadDescriptor
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.Source§impl PartialEq for ThreadDescriptor
impl PartialEq for ThreadDescriptor
impl StructuralPartialEq for ThreadDescriptor
Auto Trait Implementations§
impl Freeze for ThreadDescriptor
impl RefUnwindSafe for ThreadDescriptor
impl Send for ThreadDescriptor
impl Sync for ThreadDescriptor
impl Unpin for ThreadDescriptor
impl UnwindSafe for ThreadDescriptor
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,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
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>
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§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Layered].