pub struct TrustStore { /* private fields */ }Expand description
Stored trust decisions.
Implementations§
Source§impl TrustStore
impl TrustStore
Sourcepub fn new(agent_dir: &Path) -> TrustStore
pub fn new(agent_dir: &Path) -> TrustStore
The store in agent_dir.
Sourcepub fn get(&self, cwd: &Path) -> Result<Option<bool>>
pub fn get(&self, cwd: &Path) -> Result<Option<bool>>
The decision for cwd from it or its nearest decided ancestor, or an
error when the store cannot be read.
Sourcepub fn entry(&self, cwd: &Path) -> Result<Option<(PathBuf, bool)>>
pub fn entry(&self, cwd: &Path) -> Result<Option<(PathBuf, bool)>>
The nearest decided directory at or above cwd, and its decision, or
an error when the store cannot be read.
Trait Implementations§
Source§impl Clone for TrustStore
impl Clone for TrustStore
Auto Trait Implementations§
impl Freeze for TrustStore
impl RefUnwindSafe for TrustStore
impl Send for TrustStore
impl Sync for TrustStore
impl Unpin for TrustStore
impl UnsafeUnpin for TrustStore
impl UnwindSafe for TrustStore
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