Struct undo::record::Queue [−][src]
pub struct Queue<'a, A, F> { /* fields omitted */ }
Expand description
Wraps a record and gives it batch queue functionality.
Examples
let mut string = String::new(); let mut record = Record::new(); let mut queue = record.queue(); queue.apply(Add('a')); queue.apply(Add('b')); queue.apply(Add('c')); assert_eq!(string, ""); queue.commit(&mut string).unwrap()?; assert_eq!(string, "abc");
Implementations
Applies the queued actions.
Errors
If an error occurs, it stops applying the actions and returns the error.
Returns a checkpoint.
Trait Implementations
Auto Trait Implementations
impl<'a, A, F> RefUnwindSafe for Queue<'a, A, F> where
A: RefUnwindSafe,
F: RefUnwindSafe,
impl<'a, A, F> !UnwindSafe for Queue<'a, A, F>