[][src]Struct line_diff::Config

pub struct Config { /* fields omitted */ }

Configuration struct for comparing two lines

Implementations

impl Config[src]

pub fn from_cmd_args() -> Config[src]

Create a config struct by using command line arguments

pub fn from_lines(
    sort: bool,
    lowercase: bool,
    separators: Vec<char>,
    l1: &str,
    l2: &str
) -> Config
[src]

Create a Config struct that can be used to compare two lines that are given as &str

  • sort Whether or not to sort chunks before comparing
  • lowercase Whether or not to convert chunks to lowercase before comparing
  • separators List of separators to use for splitting lines into chunks
  • l1 The first line
  • l2 The second line

pub fn from_file(
    sort: bool,
    lowercase: bool,
    separators: Vec<char>,
    filepath: PathBuf
) -> Config
[src]

Create a Config struct that can be used to compare two lines that are stored in a single file

  • sort Whether or not to sort chunks before comparing
  • lowercase Whether or not to convert chunks to lowercase before comparing
  • separators List of separators to use for splitting lines into chunks
  • filepath Path to the file that contains the two lines

Trait Implementations

impl Debug for Config[src]

impl StructOpt for Config[src]

impl StructOptInternal for Config[src]

Auto Trait Implementations

impl RefUnwindSafe for Config

impl Send for Config

impl Sync for Config

impl Unpin for Config

impl UnwindSafe for Config

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.