pub struct DumpOptions<'a> {
pub start_rev: Option<Revnum>,
pub end_rev: Option<Revnum>,
pub incremental: bool,
pub use_deltas: bool,
pub include_revprops: bool,
pub include_changes: bool,
pub notify_func: Option<&'a dyn Fn(&Notify<'_>)>,
pub filter_func: Option<Box<dyn FnMut(&Root<'_>, &str) -> Result<bool, Error<'static>> + 'a>>,
pub cancel_func: Option<&'a dyn Fn() -> Result<(), Error<'static>>>,
}Expand description
Options for repository dump operations.
Fields§
§start_rev: Option<Revnum>Starting revision (None for revision 0).
end_rev: Option<Revnum>Ending revision (None for HEAD).
incremental: boolIf true, produce incremental dump (only changes since start_rev).
use_deltas: boolIf true, use deltas for file contents.
include_revprops: boolIf true, include revision properties.
include_changes: boolIf true, include node changes.
notify_func: Option<&'a dyn Fn(&Notify<'_>)>Optional notification callback.
filter_func: Option<Box<dyn FnMut(&Root<'_>, &str) -> Result<bool, Error<'static>> + 'a>>Optional filter callback to control which paths are dumped.
cancel_func: Option<&'a dyn Fn() -> Result<(), Error<'static>>>Optional cancellation callback.
Implementations§
Source§impl<'a> DumpOptions<'a>
impl<'a> DumpOptions<'a>
Sourcepub fn with_start_rev(self, rev: Revnum) -> Self
pub fn with_start_rev(self, rev: Revnum) -> Self
Sets the starting revision.
Sourcepub fn with_end_rev(self, rev: Revnum) -> Self
pub fn with_end_rev(self, rev: Revnum) -> Self
Sets the ending revision.
Sourcepub fn with_incremental(self, incremental: bool) -> Self
pub fn with_incremental(self, incremental: bool) -> Self
Sets whether to produce an incremental dump.
Sourcepub fn with_use_deltas(self, use_deltas: bool) -> Self
pub fn with_use_deltas(self, use_deltas: bool) -> Self
Sets whether to use deltas for file contents.
Sourcepub fn with_include_revprops(self, include: bool) -> Self
pub fn with_include_revprops(self, include: bool) -> Self
Sets whether to include revision properties.
Sourcepub fn with_include_changes(self, include: bool) -> Self
pub fn with_include_changes(self, include: bool) -> Self
Sets whether to include node changes.
Trait Implementations§
Source§impl<'a> Default for DumpOptions<'a>
impl<'a> Default for DumpOptions<'a>
Source§fn default() -> DumpOptions<'a>
fn default() -> DumpOptions<'a>
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl<'a> Freeze for DumpOptions<'a>
impl<'a> !RefUnwindSafe for DumpOptions<'a>
impl<'a> !Send for DumpOptions<'a>
impl<'a> !Sync for DumpOptions<'a>
impl<'a> Unpin for DumpOptions<'a>
impl<'a> UnsafeUnpin for DumpOptions<'a>
impl<'a> !UnwindSafe for DumpOptions<'a>
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