pub struct VersionedRecord<T: Clone> { /* private fields */ }Expand description
A versioned record that stores a history of values.
Implementations§
Source§impl<T: Clone> VersionedRecord<T>
impl<T: Clone> VersionedRecord<T>
Sourcepub fn at_version(&self, n: usize) -> Option<&T>
pub fn at_version(&self, n: usize) -> Option<&T>
Returns the value at version n (0-indexed), or None.
Sourcepub fn has_history(&self) -> bool
pub fn has_history(&self) -> bool
Returns true if more than one version exists.
Auto Trait Implementations§
impl<T> Freeze for VersionedRecord<T>
impl<T> RefUnwindSafe for VersionedRecord<T>where
T: RefUnwindSafe,
impl<T> Send for VersionedRecord<T>where
T: Send,
impl<T> Sync for VersionedRecord<T>where
T: Sync,
impl<T> Unpin for VersionedRecord<T>where
T: Unpin,
impl<T> UnsafeUnpin for VersionedRecord<T>
impl<T> UnwindSafe for VersionedRecord<T>where
T: 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