pub struct AppPath { /* private fields */ }Expand description
A validated C-compatible app path passed through the FFI boundary.
Implementations§
Source§impl AppPath
impl AppPath
pub fn as_c_str(&self) -> &CStr
Sourcepub fn suggested_host_app() -> Option<Self>
pub fn suggested_host_app() -> Option<Self>
Returns a best-effort guess for the app bundle users are most likely trying to grant permission to in the current launch context.
If the current executable lives inside an .app bundle, that bundle is
returned. Otherwise, this walks up the parent process chain and returns
the first enclosing .app bundle it finds, which covers common cases
like Terminal, iTerm, or an IDE-integrated terminal.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for AppPath
impl RefUnwindSafe for AppPath
impl Send for AppPath
impl Sync for AppPath
impl Unpin for AppPath
impl UnsafeUnpin for AppPath
impl UnwindSafe for AppPath
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