pub struct HStraceBuilder { /* private fields */ }Expand description
Build hstrace
Implementations§
Source§impl HStraceBuilder
impl HStraceBuilder
pub fn new() -> Self
Sourcepub fn program(self, program: &str) -> Self
pub fn program(self, program: &str) -> Self
Set the program to be started and traced. Do not use pid arg if program is used
Sourcepub fn arg(self, arg: &str) -> Self
pub fn arg(self, arg: &str) -> Self
Set single argument for a program. If multiple arguments, use args
Sourcepub fn pid(self, pid: usize) -> Self
pub fn pid(self, pid: usize) -> Self
Set a pid to be traced. Tracer will attach to the pid when started. Do not use program arg if pid is used
Sourcepub fn options(self, options: TraceOptions) -> Self
pub fn options(self, options: TraceOptions) -> Self
Set the options to be used when tracing
Sourcepub fn set_exit_receiver(self, set_exit_receiver: Receiver<()>) -> Self
pub fn set_exit_receiver(self, set_exit_receiver: Receiver<()>) -> Self
Sets the mpsc::Receiver<T> to be used if tracing needs to be stopped while in progress
pub fn build(self) -> HStrace
Auto Trait Implementations§
impl Freeze for HStraceBuilder
impl RefUnwindSafe for HStraceBuilder
impl Send for HStraceBuilder
impl Sync for HStraceBuilder
impl Unpin for HStraceBuilder
impl UnwindSafe for HStraceBuilder
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