pub enum SymlinkPolicy {
Follow,
NoFollow,
}Expand description
Whether a capped file read may follow a symbolic link.
NoFollow is implemented with the operating
system’s atomic O_NOFOLLOW open on unix when Cargo feature libc is
enabled. Builds without that feature, and other platforms, return
DocumentError::UnsupportedOperation rather than pretending a
check-before-open sequence provides the same guarantee.
Variants§
Follow
Follow a symbolic link in the same way as File::open.
NoFollow
Refuse a symbolic-link final path component atomically.
This requires Cargo feature libc on unix.
Trait Implementations§
Source§impl Clone for SymlinkPolicy
impl Clone for SymlinkPolicy
Source§fn clone(&self) -> SymlinkPolicy
fn clone(&self) -> SymlinkPolicy
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 Copy for SymlinkPolicy
Source§impl Debug for SymlinkPolicy
impl Debug for SymlinkPolicy
Source§impl Default for SymlinkPolicy
impl Default for SymlinkPolicy
Source§fn default() -> SymlinkPolicy
fn default() -> SymlinkPolicy
Returns the “default value” for a type. Read more
impl Eq for SymlinkPolicy
Source§impl PartialEq for SymlinkPolicy
impl PartialEq for SymlinkPolicy
impl StructuralPartialEq for SymlinkPolicy
Auto Trait Implementations§
impl Freeze for SymlinkPolicy
impl RefUnwindSafe for SymlinkPolicy
impl Send for SymlinkPolicy
impl Sync for SymlinkPolicy
impl Unpin for SymlinkPolicy
impl UnsafeUnpin for SymlinkPolicy
impl UnwindSafe for SymlinkPolicy
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.