pub struct DiffTracker { /* private fields */ }Implementations§
Source§impl DiffTracker
impl DiffTracker
pub fn new(max_entries: usize) -> Self
pub fn advance_clock(&mut self, dt: u64)
pub fn record(&mut self, property: &str, old_value: &str, new_value: &str)
pub fn count(&self) -> usize
pub fn is_empty(&self) -> bool
pub fn latest(&self) -> Option<&DiffEntry>
pub fn by_property(&self, property: &str) -> Vec<&DiffEntry>
pub fn since(&self, timestamp: u64) -> Vec<&DiffEntry>
pub fn changed_properties(&self) -> Vec<String>
pub fn has_changes_for(&self, property: &str) -> bool
pub fn clear(&mut self)
pub fn revert_latest(&mut self) -> Option<DiffEntry>
pub fn all_entries(&self) -> &[DiffEntry]
pub fn max_entries(&self) -> usize
Trait Implementations§
Source§impl Clone for DiffTracker
impl Clone for DiffTracker
Source§fn clone(&self) -> DiffTracker
fn clone(&self) -> DiffTracker
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 moreAuto Trait Implementations§
impl Freeze for DiffTracker
impl RefUnwindSafe for DiffTracker
impl Send for DiffTracker
impl Sync for DiffTracker
impl Unpin for DiffTracker
impl UnsafeUnpin for DiffTracker
impl UnwindSafe for DiffTracker
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