Skip to main content

ProbeBasic

Struct ProbeBasic 

Source
pub struct ProbeBasic<L: RawMutex + 'static> { /* private fields */ }
Expand description

The basic information of a probe.

Implementations§

Source§

impl<L: RawMutex + 'static> ProbeBasic<L>

Source

pub fn call_pre_handler(&self, pt_regs: &mut PtRegs)

Call the pre handler function.

Source

pub fn call_post_handler(&self, pt_regs: &mut PtRegs)

Call the post handler function.

Source

pub fn call_fault_handler(&self, pt_regs: &mut PtRegs)

Call the fault handler function.

Source

pub fn call_event_callback(&self, pt_regs: &mut PtRegs)

Call the event callback function.

Source

pub fn register_event_callback( &self, callback_id: u32, callback: Arc<dyn CallBackFunc>, )

Register the event callback function.

Source

pub fn unregister_event_callback(&self, callback_id: u32)

Unregister the event callback function.

Source

pub fn disable(&self)

Disable the probe point.

Source

pub fn enable(&self)

Enable the probe point.

Source

pub fn is_enabled(&self) -> bool

Check if the probe point is enabled.

Source

pub fn symbol(&self) -> Option<&str>

Get the function name of the probe point.

Trait Implementations§

Source§

impl<L: RawMutex + 'static> Debug for ProbeBasic<L>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<L: RawMutex + 'static, F: KprobeAuxiliaryOps> From<ProbeBuilder<F>> for ProbeBasic<L>

Source§

fn from(value: ProbeBuilder<F>) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

§

impl<L> !Freeze for ProbeBasic<L>

§

impl<L> !RefUnwindSafe for ProbeBasic<L>

§

impl<L> !UnwindSafe for ProbeBasic<L>

§

impl<L> Send for ProbeBasic<L>
where L: Send,

§

impl<L> Sync for ProbeBasic<L>
where L: Sync,

§

impl<L> Unpin for ProbeBasic<L>
where L: Unpin,

§

impl<L> UnsafeUnpin for ProbeBasic<L>
where L: UnsafeUnpin,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ProbeData for T
where T: Any + Send + Sync + Debug,

Source§

fn as_any(&self) -> &(dyn Any + 'static)

Get a reference to the data as a dyn Any.
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.