Skip to main content

CapControl

Trait CapControl 

Source
pub trait CapControl {
    // Required methods
    fn retain(&self, id: CapId);
    fn release(&self, id: CapId);
}
Expand description

Control surface a capability handle uses to release its reference.

The kernel implements this; cap.rs stays independent of the kernel so the two can be reasoned about separately.

Required Methods§

Source

fn retain(&self, id: CapId)

Add one reference to a capability.

Source

fn release(&self, id: CapId)

Drop one reference; the provider is notified when the last one goes.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§