pub struct CapabilityChecker { /* private fields */ }Expand description
Check-only retained path used by every host-mediated consuming act.
This handle deliberately carries no verdict. Every call reads current table state, so retaining the handle across revoke cannot retain authority.
Implementations§
Source§impl CapabilityChecker
impl CapabilityChecker
Sourcepub const fn component_id(&self) -> ComponentId
pub const fn component_id(&self) -> ComponentId
Returns the component identity whose current authority this checker evaluates.
Sourcepub fn check(
&self,
capability: &Capability,
) -> Result<CheckVerdict, CapabilityCheckError>
pub fn check( &self, capability: &Capability, ) -> Result<CheckVerdict, CapabilityCheckError>
Evaluates one consuming act against current grants and events one denial.
§Errors
Returns a synchronization error if table or event delivery state was
poisoned. Denial itself is a successful typed CheckVerdict::Denied.
Trait Implementations§
Source§impl Clone for CapabilityChecker
impl Clone for CapabilityChecker
Source§fn clone(&self) -> CapabilityChecker
fn clone(&self) -> CapabilityChecker
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for CapabilityChecker
impl RefUnwindSafe for CapabilityChecker
impl Send for CapabilityChecker
impl Sync for CapabilityChecker
impl Unpin for CapabilityChecker
impl UnsafeUnpin for CapabilityChecker
impl UnwindSafe for CapabilityChecker
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