pub struct Undo { /* private fields */ }Implementations§
Source§impl Undo
impl Undo
pub fn new(remove: usize, insert: Vec<StackItem>, tokens: Vec<String>) -> Self
pub fn is_empty(&self) -> bool
pub fn merge( &mut self, remove: usize, insert: Vec<StackItem>, token: Option<&str>, )
pub fn add_tokens(&mut self, token: Option<&str>, tokens: Vec<String>)
pub fn clear(&mut self)
pub fn apply_to(&mut self, stack: &mut ValueStack) -> Self
Trait Implementations§
impl StructuralPartialEq for Undo
Auto Trait Implementations§
impl Freeze for Undo
impl !RefUnwindSafe for Undo
impl !Send for Undo
impl !Sync for Undo
impl Unpin for Undo
impl !UnwindSafe for Undo
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more