Skip to main content

CacheStore

Trait CacheStore 

Source
pub trait CacheStore {
    // Required methods
    fn get_info(&self, pid: u32) -> Option<ProcInfo>;
    fn insert_info(&self, pid: u32, info: ProcInfo);
}
Expand description

Trait for process info cache.

Implement this trait to provide your own cache backend.

Required Methods§

Source

fn get_info(&self, pid: u32) -> Option<ProcInfo>

Get cached process info by PID.

Source

fn insert_info(&self, pid: u32, info: ProcInfo)

Insert or update process info.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§