pub struct CapRights(/* private fields */);Expand description
Capability rights bitmap.
Rights determine what operations are permitted on the capability’s target object. Rights are checked at syscall time and cannot be escalated.
Implementations§
Source§impl CapRights
impl CapRights
Sourcepub const PROVE: Self
pub const PROVE: Self
Right to generate proof tokens for this object.
Required for vector_put_proved and graph_apply_proved.
Sourcepub const GRANT_ONCE: Self
pub const GRANT_ONCE: Self
Non-transitive grant right (cannot be further delegated). See Section 20.2 of ADR-087.
Sourcepub const fn intersection(self, other: Self) -> Self
pub const fn intersection(self, other: Self) -> Self
Returns the intersection of two rights sets.
Sourcepub const fn difference(self, other: Self) -> Self
pub const fn difference(self, other: Self) -> Self
Returns the difference (rights in self but not in other).
Sourcepub const fn is_subset_of(&self, other: Self) -> bool
pub const fn is_subset_of(&self, other: Self) -> bool
Checks if this rights set is a subset of another (can be derived from it).
Trait Implementations§
Source§impl BitAndAssign for CapRights
impl BitAndAssign for CapRights
Source§fn bitand_assign(&mut self, rhs: Self)
fn bitand_assign(&mut self, rhs: Self)
Performs the
&= operation. Read moreSource§impl BitOrAssign for CapRights
impl BitOrAssign for CapRights
Source§fn bitor_assign(&mut self, rhs: Self)
fn bitor_assign(&mut self, rhs: Self)
Performs the
|= operation. Read moreimpl Copy for CapRights
impl Eq for CapRights
impl StructuralPartialEq for CapRights
Auto Trait Implementations§
impl Freeze for CapRights
impl RefUnwindSafe for CapRights
impl Send for CapRights
impl Sync for CapRights
impl Unpin for CapRights
impl UnsafeUnpin for CapRights
impl UnwindSafe for CapRights
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more