pub fn stop(&mut self) {
        match self._stop() {
            Ok(_) => log::trace!(target: LOG_TAG, "Agent stopped"),
            Err(_) => log::error!(target: LOG_TAG, "Error stopping agent"),
        }
    }
/// Stop the agent. The agent will stop profiling and send a last report to the server.
/// # Example
/// ```ignore
/// let agent = PyroscopeAgent::builder("http://localhost:8080", "my-app").build()?;
/// agent.start()?;
/// // Expensive operation
/// agent.stop();
/// ```
Stop the agent. The agent will stop profiling and send a last report to the server.
Stop the agent . The agent will stop profiling and send a last report to the server .
pub fn stop(&mut self) {
        match self._stop() {
            Ok(_) => log::trace!(target: LOG_TAG, "Agent stopped"),
            Err(_) => log::error!(target: LOG_TAG, "Error stopping agent"),
        }
    }
pub fn stop ( & mut self ) { match self . _stop ( ) { Ok ( _ ) => log :: trace ! ( target LOG_TAG " " ) , Err ( _ ) => log :: error ! ( target LOG_TAG " " ) , } }
Stop the agent.
Stop the agent .
&mut self
&mut self
example
None