pub struct DiffRowGenerator { /* private fields */ }Expand description
Primary generator for DiffRow side-by-side views.
Implementations§
Source§impl DiffRowGenerator
impl DiffRowGenerator
Sourcepub fn split_string_preserve_delimiter(
str_input: &str,
pattern: &Regex,
) -> Vec<String>
pub fn split_string_preserve_delimiter( str_input: &str, pattern: &Regex, ) -> Vec<String>
Helper to forward delimiter splitting.
Sourcepub fn ignore_white_spaces(&self) -> bool
pub fn ignore_white_spaces(&self) -> bool
Returns whether whitespace differences are ignored.
Sourcepub fn generate_diff_rows(
&self,
original: &[String],
revised: &[String],
) -> Vec<DiffRow>
pub fn generate_diff_rows( &self, original: &[String], revised: &[String], ) -> Vec<DiffRow>
Generates DiffRow items comparing two string sequences.
Sourcepub fn generate_diff_rows_from_patch(
&self,
original: &[String],
patch: &mut Patch<String>,
) -> Vec<DiffRow>
pub fn generate_diff_rows_from_patch( &self, original: &[String], patch: &mut Patch<String>, ) -> Vec<DiffRow>
Generates DiffRow items comparing an original text sequence against an existing Patch.
pub fn normalize_lines(&self, list: &[String]) -> Vec<String>
Trait Implementations§
Source§impl Clone for DiffRowGenerator
impl Clone for DiffRowGenerator
Source§fn clone(&self) -> DiffRowGenerator
fn clone(&self) -> DiffRowGenerator
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 !RefUnwindSafe for DiffRowGenerator
impl !UnwindSafe for DiffRowGenerator
impl Freeze for DiffRowGenerator
impl Send for DiffRowGenerator
impl Sync for DiffRowGenerator
impl Unpin for DiffRowGenerator
impl UnsafeUnpin for DiffRowGenerator
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