#[non_exhaustive]pub enum DirOp<P: AsRef<Path>> {
SetPermissions {
path: P,
permissions: Permissions,
},
RemoveDir {
path: P,
},
RemoveDirAll {
path: P,
},
CreateDir {
path: P,
},
CreateDirAll {
path: P,
},
RemoveFile {
path: P,
},
Rename {
from: P,
to: P,
},
Copy {
from: P,
to: P,
},
HardLink {
from: P,
to: P,
},
}
Expand description
List of operations that can be done on a filesystem.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
SetPermissions
RemoveDir
Fields
§
path: P
RemoveDirAll
Fields
§
path: P
CreateDir
Fields
§
path: P
CreateDirAll
Fields
§
path: P
RemoveFile
Fields
§
path: P
Rename
Copy
HardLink
Implementations§
Trait Implementations§
source§impl<'de, P> Deserialize<'de> for DirOp<P>
impl<'de, P> Deserialize<'de> for DirOp<P>
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl<P: Ord + AsRef<Path>> Ord for DirOp<P>
impl<P: Ord + AsRef<Path>> Ord for DirOp<P>
source§impl<P: PartialEq + AsRef<Path>> PartialEq for DirOp<P>
impl<P: PartialEq + AsRef<Path>> PartialEq for DirOp<P>
source§impl<P: PartialOrd + AsRef<Path>> PartialOrd for DirOp<P>
impl<P: PartialOrd + AsRef<Path>> PartialOrd for DirOp<P>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl<P: Copy + AsRef<Path>> Copy for DirOp<P>
impl<P: Eq + AsRef<Path>> Eq for DirOp<P>
impl<P: AsRef<Path>> StructuralEq for DirOp<P>
impl<P: AsRef<Path>> StructuralPartialEq for DirOp<P>
Auto Trait Implementations§
impl<P> RefUnwindSafe for DirOp<P>where
P: RefUnwindSafe,
impl<P> Send for DirOp<P>where
P: Send,
impl<P> Sync for DirOp<P>where
P: Sync,
impl<P> Unpin for DirOp<P>where
P: Unpin,
impl<P> UnwindSafe for DirOp<P>where
P: 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