pub struct CheckpointStore { /* private fields */ }Implementations§
Source§impl CheckpointStore
impl CheckpointStore
pub fn new(max_checkpoints: usize) -> Self
pub fn advance_clock(&mut self, dt: u64)
pub fn save(&mut self, name: &str, data: Vec<u8>)
pub fn restore(&self, name: &str) -> Option<&[u8]>
pub fn remove(&mut self, name: &str) -> bool
pub fn count(&self) -> usize
pub fn names(&self) -> Vec<&str>
pub fn latest(&self) -> Option<&Checkpoint>
pub fn oldest(&self) -> Option<&Checkpoint>
pub fn total_bytes(&self) -> usize
pub fn contains(&self, name: &str) -> bool
pub fn clear(&mut self)
pub fn max_checkpoints(&self) -> usize
Trait Implementations§
Source§impl Clone for CheckpointStore
impl Clone for CheckpointStore
Source§fn clone(&self) -> CheckpointStore
fn clone(&self) -> CheckpointStore
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 CheckpointStore
impl RefUnwindSafe for CheckpointStore
impl Send for CheckpointStore
impl Sync for CheckpointStore
impl Unpin for CheckpointStore
impl UnsafeUnpin for CheckpointStore
impl UnwindSafe for CheckpointStore
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