Struct undo::history::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().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.