pub struct Either<'a>(/* private fields */);
Expand description
Regex syntax for the alternation or “or” operator of the patterns in iterator input, and the alternation is placed in a group
§Examples
use readable_regex::solvers::Either;
use readable_regex::ReadableRe::Raw;
assert_eq!(Either::new([Raw("a"), Raw("b"), Raw("c")]).to_string(), "a|b|c")
Implementations§
Source§impl<'a> Either<'a>
impl<'a> Either<'a>
pub fn new(iter: impl IntoIterator<Item = ReadableRe<'a>>) -> Self
Trait Implementations§
Source§impl<'a> FromIterator<ReadableRe<'a>> for Either<'a>
impl<'a> FromIterator<ReadableRe<'a>> for Either<'a>
Source§fn from_iter<T: IntoIterator<Item = ReadableRe<'a>>>(iter: T) -> Self
fn from_iter<T: IntoIterator<Item = ReadableRe<'a>>>(iter: T) -> Self
Creates a value from an iterator. Read more
Auto Trait Implementations§
impl<'a> Freeze for Either<'a>
impl<'a> RefUnwindSafe for Either<'a>
impl<'a> Send for Either<'a>
impl<'a> Sync for Either<'a>
impl<'a> Unpin for Either<'a>
impl<'a> UnwindSafe for Either<'a>
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