Struct redbpf::load::Loaded [−][src]
pub struct Loaded {
pub module: Module,
pub events: UnboundedReceiver<(String, <PerfMessageStream as Stream>::Item)>,
}
Expand description
The Loaded
object returned by load()
.
Fields
module: Module
events: UnboundedReceiver<(String, <PerfMessageStream as Stream>::Item)>
The stream of events emitted by the BPF programs.
Example
use std::path::Path;
use futures::stream::StreamExt;
use redbpf::load::Loader;
let mut loader = Loader::load_file(&Path::new("probe.elf")).unwrap();
while let Some((map_name, events)) = loader.events.next().await {
for event in events {
// ...
}
}
Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Loaded
impl !UnwindSafe for Loaded
Blanket Implementations
Mutably borrows from an owned value. Read more
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more