pub struct HistoryConfig {
pub max_depth: usize,
pub max_bytes: usize,
pub merge_config: MergeConfig,
}Expand description
Configuration for the history manager.
Fields§
§max_depth: usizeMaximum number of commands to keep in undo history.
max_bytes: usizeMaximum total bytes for all commands (0 = unlimited).
merge_config: MergeConfigConfiguration for command merging.
Implementations§
Source§impl HistoryConfig
impl HistoryConfig
Sourcepub fn new(max_depth: usize, max_bytes: usize) -> Self
pub fn new(max_depth: usize, max_bytes: usize) -> Self
Create a new configuration with custom limits.
Sourcepub fn with_merge_config(self, config: MergeConfig) -> Self
pub fn with_merge_config(self, config: MergeConfig) -> Self
Set the merge configuration.
Trait Implementations§
Source§impl Clone for HistoryConfig
impl Clone for HistoryConfig
Source§fn clone(&self) -> HistoryConfig
fn clone(&self) -> HistoryConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for HistoryConfig
impl Debug for HistoryConfig
Auto Trait Implementations§
impl Freeze for HistoryConfig
impl RefUnwindSafe for HistoryConfig
impl Send for HistoryConfig
impl Sync for HistoryConfig
impl Unpin for HistoryConfig
impl UnsafeUnpin for HistoryConfig
impl UnwindSafe for HistoryConfig
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