pub struct PolicyEnforcedFs { /* private fields */ }Expand description
A filesystem provider that wraps another and enforces a RuntimePolicy.
All read operations check policy.is_path_readable(); all write operations
check policy.is_path_writable(). If the check fails,
io::ErrorKind::PermissionDenied is returned.
Implementations§
Source§impl PolicyEnforcedFs
impl PolicyEnforcedFs
pub fn new( inner: Arc<dyn FileSystemProvider>, policy: Arc<RuntimePolicy>, ) -> Self
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PolicyEnforcedFs
impl !RefUnwindSafe for PolicyEnforcedFs
impl Send for PolicyEnforcedFs
impl Sync for PolicyEnforcedFs
impl Unpin for PolicyEnforcedFs
impl UnsafeUnpin for PolicyEnforcedFs
impl !UnwindSafe for PolicyEnforcedFs
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