Struct redbpf::PerCpuValues [−][src]
pub struct PerCpuValues<T: Clone>(_);
Expand description
A structure representing values of per-cpu map structures such as PerCpuArray
It is a kind of newtype of Box<[T]>
. The length of the slice is always
the same with cpus::get_possible_num
.
It also implements Deref
and DerefMut
so it can be used as a normal
array.
Example
use redbpf::PerCpuValues;
let mut values = PerCpuValues::<u64>::new(0);
values[0] = 1;
Implementations
Trait Implementations
Auto Trait Implementations
impl<T> RefUnwindSafe for PerCpuValues<T> where
T: RefUnwindSafe,
impl<T> Send for PerCpuValues<T> where
T: Send,
impl<T> Sync for PerCpuValues<T> where
T: Sync,
impl<T> Unpin for PerCpuValues<T>
impl<T> UnwindSafe for PerCpuValues<T> where
T: UnwindSafe,
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