Struct linux_taskstats::Client

source ·
pub struct Client { /* private fields */ }
Expand description

Interface to access kernel taskstats API through the netlink socket.

Implementations

Open netlink socket against kernel and create a new instance of Client

Errors
  • when netlink socket initialization failed
  • when kernel doesn’t offer family id for taskstats

Obtain taskstats for given task ID

Arguments
  • tid - Kernel task ID (could be either pid for per-task pid a.k.a tid)
Return
  • TaskStats storing the target task’s stats
Errors
  • when netlink socket failed
  • when kernel responded error
  • when the returned data couldn’t be interpreted

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

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

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.