[−][src]Struct grep_cli::DecompressionMatcherBuilder
A builder for a matcher that determines which files get decompressed.
Methods
impl DecompressionMatcherBuilder
[src]
pub fn new() -> DecompressionMatcherBuilder
[src]
Create a new builder for configuring a decompression matcher.
pub fn build(&self) -> Result<DecompressionMatcher, CommandError>
[src]
Build a matcher for determining how to decompress files.
If there was a problem compiling the matcher, then an error is returned.
pub fn defaults(&mut self, yes: bool) -> &mut DecompressionMatcherBuilder
[src]
When enabled, the default matching rules will be compiled into this matcher before any other associations. When disabled, only the rules explicitly given to this builder will be used.
This is enabled by default.
pub fn associate<P, I, A>(
&mut self,
glob: &str,
program: P,
args: I
) -> &mut DecompressionMatcherBuilder where
P: AsRef<OsStr>,
I: IntoIterator<Item = A>,
A: AsRef<OsStr>,
[src]
&mut self,
glob: &str,
program: P,
args: I
) -> &mut DecompressionMatcherBuilder where
P: AsRef<OsStr>,
I: IntoIterator<Item = A>,
A: AsRef<OsStr>,
Associates a glob with a command to decompress files matching the glob.
If multiple globs match the same file, then the most recently added glob takes precedence.
The syntax for the glob is documented in the
globset
crate.
Trait Implementations
impl Clone for DecompressionMatcherBuilder
[src]
fn clone(&self) -> DecompressionMatcherBuilder
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for DecompressionMatcherBuilder
[src]
impl Default for DecompressionMatcherBuilder
[src]
Auto Trait Implementations
impl RefUnwindSafe for DecompressionMatcherBuilder
impl Send for DecompressionMatcherBuilder
impl Sync for DecompressionMatcherBuilder
impl Unpin for DecompressionMatcherBuilder
impl UnwindSafe for DecompressionMatcherBuilder
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,