pub struct MoveBuilder { /* private fields */ }Expand description
Build a move mutation. Records matching filter are relocated into
to_folder (created if needed). Filename collisions at the destination
surface as MutationErrors in the report.
Implementations§
Source§impl MoveBuilder
impl MoveBuilder
pub fn new( folder: impl Into<String>, to_folder: impl Into<String>, filter: Expr, ) -> Self
Sourcepub fn recursive(self, yes: bool) -> Self
pub fn recursive(self, yes: bool) -> Self
Recurse into subfolders when selecting records to move (default
false — only files directly in folder are considered).
Sourcepub fn write_options(self, opts: WriteOptions) -> Self
pub fn write_options(self, opts: WriteOptions) -> Self
Replace the writer::WriteOptions used by execute.
Sourcepub fn fsync(self, yes: bool) -> Self
pub fn fsync(self, yes: bool) -> Self
Convenience: enable durable moves (fsync source + dest dirents).
pub fn plan(&self, vault: &Vault) -> Result<MutationReport>
pub fn execute(self, vault: &Vault) -> Result<MutationReport>
Trait Implementations§
Source§impl Clone for MoveBuilder
impl Clone for MoveBuilder
Source§fn clone(&self) -> MoveBuilder
fn clone(&self) -> MoveBuilder
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 moreAuto Trait Implementations§
impl Freeze for MoveBuilder
impl RefUnwindSafe for MoveBuilder
impl Send for MoveBuilder
impl Sync for MoveBuilder
impl Unpin for MoveBuilder
impl UnsafeUnpin for MoveBuilder
impl UnwindSafe for MoveBuilder
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