pub struct Permissions<B>where
B: PermissionsBackend,{ /* private fields */ }Expand description
Static-dispatch permissions wrapper.
Implementations§
Source§impl<B> Permissions<B>where
B: PermissionsBackend,
impl<B> Permissions<B>where
B: PermissionsBackend,
pub const fn new() -> Permissions<B>
pub fn check( targets: &[CaptureTarget], backends: &Backends, ) -> Result<PermissionReport, CapabilityError>
pub fn check_request( request: &CaptureRequest, ) -> Result<PermissionReport, CapabilityError>
pub fn check_kinds( kinds: &[PermissionKind], backends: &Backends, ) -> Result<PermissionReport, CapabilityError>
pub fn request( targets: &[CaptureTarget], backends: &Backends, timeout: Duration, open_settings_if_denied: bool, ) -> Result<PermissionReport, CapabilityError>
pub fn request_for_capture_request( request: &CaptureRequest, timeout: Duration, open_settings_if_denied: bool, ) -> Result<PermissionReport, CapabilityError>
pub fn request_kinds( kinds: &[PermissionKind], backends: &Backends, timeout: Duration, open_settings_if_denied: bool, ) -> Result<PermissionReport, CapabilityError>
Trait Implementations§
Source§impl<B> Clone for Permissions<B>where
B: Clone + PermissionsBackend,
impl<B> Clone for Permissions<B>where
B: Clone + PermissionsBackend,
Source§fn clone(&self) -> Permissions<B>
fn clone(&self) -> Permissions<B>
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 moreimpl<B> Copy for Permissions<B>where
B: Copy + PermissionsBackend,
Source§impl<B> Debug for Permissions<B>where
B: Debug + PermissionsBackend,
impl<B> Debug for Permissions<B>where
B: Debug + PermissionsBackend,
Source§impl<B> Default for Permissions<B>where
B: Default + PermissionsBackend,
impl<B> Default for Permissions<B>where
B: Default + PermissionsBackend,
Source§fn default() -> Permissions<B>
fn default() -> Permissions<B>
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl<B> Freeze for Permissions<B>
impl<B> RefUnwindSafe for Permissions<B>where
B: RefUnwindSafe,
impl<B> Send for Permissions<B>
impl<B> Sync for Permissions<B>
impl<B> Unpin for Permissions<B>where
B: Unpin,
impl<B> UnsafeUnpin for Permissions<B>
impl<B> UnwindSafe for Permissions<B>where
B: UnwindSafe,
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