pub struct CSwitchEtwEvent {
pub new_thread_id: Option<u32>,
pub old_thread_id: Option<u32>,
pub new_thread_priority: Option<i32>,
pub old_thread_priority: Option<i32>,
pub previous_c_state: Option<u32>,
pub old_thread_wait_reason: Option<i32>,
pub old_thread_wait_mode: Option<i32>,
pub old_thread_state: Option<i32>,
pub old_thread_wait_ideal_processor: Option<i32>,
pub new_thread_wait_time: Option<u32>,
}Expand description
Proto definition based on the Thread_v2 CSwitch class definition See: https://learn.microsoft.com/en-us/windows/win32/etw/cswitch
Fields§
§new_thread_id: Option<u32>New thread ID after the switch.
old_thread_id: Option<u32>Previous thread ID.
new_thread_priority: Option<i32>Thread priority of the new thread.
old_thread_priority: Option<i32>Thread priority of the previous thread.
previous_c_state: Option<u32>The index of the C-state that was last used by the processor. A value of 0 represents the lightest idle state with higher values representing deeper C-states.
old_thread_wait_reason: Option<i32>§old_thread_wait_mode: Option<i32>§old_thread_state: Option<i32>§old_thread_wait_ideal_processor: Option<i32>Ideal wait time of the previous thread.
new_thread_wait_time: Option<u32>Wait time for the new thread.
Implementations§
Source§impl CSwitchEtwEvent
impl CSwitchEtwEvent
Sourcepub fn new_thread_id(&self) -> u32
pub fn new_thread_id(&self) -> u32
Returns the value of new_thread_id, or the default value if new_thread_id is unset.
Sourcepub fn old_thread_id(&self) -> u32
pub fn old_thread_id(&self) -> u32
Returns the value of old_thread_id, or the default value if old_thread_id is unset.
Sourcepub fn new_thread_priority(&self) -> i32
pub fn new_thread_priority(&self) -> i32
Returns the value of new_thread_priority, or the default value if new_thread_priority is unset.
Sourcepub fn old_thread_priority(&self) -> i32
pub fn old_thread_priority(&self) -> i32
Returns the value of old_thread_priority, or the default value if old_thread_priority is unset.
Sourcepub fn previous_c_state(&self) -> u32
pub fn previous_c_state(&self) -> u32
Returns the value of previous_c_state, or the default value if previous_c_state is unset.
Sourcepub fn old_thread_wait_reason(&self) -> OldThreadWaitReason
pub fn old_thread_wait_reason(&self) -> OldThreadWaitReason
Returns the enum value of old_thread_wait_reason, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn set_old_thread_wait_reason(&mut self, value: OldThreadWaitReason)
pub fn set_old_thread_wait_reason(&mut self, value: OldThreadWaitReason)
Sets old_thread_wait_reason to the provided enum value.
Sourcepub fn old_thread_wait_mode(&self) -> OldThreadWaitMode
pub fn old_thread_wait_mode(&self) -> OldThreadWaitMode
Returns the enum value of old_thread_wait_mode, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn set_old_thread_wait_mode(&mut self, value: OldThreadWaitMode)
pub fn set_old_thread_wait_mode(&mut self, value: OldThreadWaitMode)
Sets old_thread_wait_mode to the provided enum value.
Sourcepub fn old_thread_state(&self) -> OldThreadState
pub fn old_thread_state(&self) -> OldThreadState
Returns the enum value of old_thread_state, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn set_old_thread_state(&mut self, value: OldThreadState)
pub fn set_old_thread_state(&mut self, value: OldThreadState)
Sets old_thread_state to the provided enum value.
Sourcepub fn old_thread_wait_ideal_processor(&self) -> i32
pub fn old_thread_wait_ideal_processor(&self) -> i32
Returns the value of old_thread_wait_ideal_processor, or the default value if old_thread_wait_ideal_processor is unset.
Sourcepub fn new_thread_wait_time(&self) -> u32
pub fn new_thread_wait_time(&self) -> u32
Returns the value of new_thread_wait_time, or the default value if new_thread_wait_time is unset.
Trait Implementations§
Source§impl Clone for CSwitchEtwEvent
impl Clone for CSwitchEtwEvent
Source§fn clone(&self) -> CSwitchEtwEvent
fn clone(&self) -> CSwitchEtwEvent
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CSwitchEtwEvent
impl Debug for CSwitchEtwEvent
Source§impl Default for CSwitchEtwEvent
impl Default for CSwitchEtwEvent
Source§fn default() -> CSwitchEtwEvent
fn default() -> CSwitchEtwEvent
Source§impl Message for CSwitchEtwEvent
impl Message for CSwitchEtwEvent
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 CSwitchEtwEvent
impl PartialEq for CSwitchEtwEvent
impl Copy for CSwitchEtwEvent
impl StructuralPartialEq for CSwitchEtwEvent
Auto Trait Implementations§
impl Freeze for CSwitchEtwEvent
impl RefUnwindSafe for CSwitchEtwEvent
impl Send for CSwitchEtwEvent
impl Sync for CSwitchEtwEvent
impl Unpin for CSwitchEtwEvent
impl UnwindSafe for CSwitchEtwEvent
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].