Struct sauron::prelude::mt_dom::patch::ChangeText [−]
pub struct ChangeText<'a> { pub node_idx: usize, pub new_node_idx: usize, pub old: &'a Text, pub new: &'a Text, }
Expand description
The patch is changing the text content of a text node
Fields
node_idx: usize
node index of the text node to be patch relative to the root node of the application
new_node_idx: usize
the new node_idx of this text
old: &'a Text
the old text is not really needed for applying the patch. but it is useful for debugging purposed, that we are changing the intended target text by visual inspection
new: &'a Text
the neew text patch
Implementations
impl<'a> ChangeText<'a>
impl<'a> ChangeText<'a>
Trait Implementations
impl<'a> Clone for ChangeText<'a>
impl<'a> Clone for ChangeText<'a>
pub fn clone(&self) -> ChangeText<'a>
pub fn clone(&self) -> ChangeText<'a>
Returns a copy of the value. Read more
Performs copy-assignment from source
. Read more
impl<'a> Debug for ChangeText<'a>
impl<'a> Debug for ChangeText<'a>
pub fn from(ct: ChangeText<'a>) -> Patch<'a, NS, TAG, ATT, VAL, EVENT>
pub fn from(ct: ChangeText<'a>) -> Patch<'a, NS, TAG, ATT, VAL, EVENT>
Performs the conversion.
impl<'a> PartialEq<ChangeText<'a>> for ChangeText<'a>
impl<'a> PartialEq<ChangeText<'a>> for ChangeText<'a>
pub fn eq(&self, other: &ChangeText<'a>) -> bool
pub fn eq(&self, other: &ChangeText<'a>) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
pub fn ne(&self, other: &ChangeText<'a>) -> bool
pub fn ne(&self, other: &ChangeText<'a>) -> bool
This method tests for !=
.
impl<'a> StructuralPartialEq for ChangeText<'a>
Auto Trait Implementations
impl<'a> RefUnwindSafe for ChangeText<'a>
impl<'a> Send for ChangeText<'a>
impl<'a> Sync for ChangeText<'a>
impl<'a> Unpin for ChangeText<'a>
impl<'a> UnwindSafe for ChangeText<'a>
Blanket Implementations
Mutably borrows from an owned value. Read more