Struct grep_searcher::Encoding
source · pub struct Encoding(/* private fields */);
Expand description
An encoding to use when searching.
An encoding can be used to configure a SearcherBuilder
to transcode
source data from an encoding to UTF-8 before searching.
An Encoding
will always be cheap to clone.
Implementations§
source§impl Encoding
impl Encoding
sourcepub fn new(label: &str) -> Result<Encoding, ConfigError>
pub fn new(label: &str) -> Result<Encoding, ConfigError>
Create a new encoding for the specified label.
The encoding label provided is mapped to an encoding via the set of available choices specified in the Encoding Standard. If the given label does not correspond to a valid encoding, then this returns an error.
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for Encoding
impl Send for Encoding
impl Sync for Encoding
impl Unpin for Encoding
impl UnwindSafe for Encoding
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