pub struct NormalizedSelectionKey(/* private fields */);
Expand description
Wraps a normalized selection and derives Eq
and Hash
, relying
on the canonical structure of the normalized form.
This ensures that logically equivalent selections (e.g., unions with reordered elements) compare equal and hash identically.
Implementations§
Source§impl NormalizedSelectionKey
impl NormalizedSelectionKey
Sourcepub fn new(sel: &Selection) -> Self
pub fn new(sel: &Selection) -> Self
Constructs a NormalizedSelectionKey
, normalizing the input
selection.
Sourcepub fn inner(&self) -> &NormalizedSelection
pub fn inner(&self) -> &NormalizedSelection
Access the normalized selection.
Sourcepub fn into_inner(self) -> NormalizedSelection
pub fn into_inner(self) -> NormalizedSelection
Consumes the key and returns the owned normalized selection.
Trait Implementations§
Source§impl Clone for NormalizedSelectionKey
impl Clone for NormalizedSelectionKey
Source§fn clone(&self) -> NormalizedSelectionKey
fn clone(&self) -> NormalizedSelectionKey
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for NormalizedSelectionKey
impl Debug for NormalizedSelectionKey
Source§impl Hash for NormalizedSelectionKey
impl Hash for NormalizedSelectionKey
Source§impl PartialEq for NormalizedSelectionKey
impl PartialEq for NormalizedSelectionKey
impl Eq for NormalizedSelectionKey
impl StructuralPartialEq for NormalizedSelectionKey
Auto Trait Implementations§
impl Freeze for NormalizedSelectionKey
impl RefUnwindSafe for NormalizedSelectionKey
impl Send for NormalizedSelectionKey
impl Sync for NormalizedSelectionKey
impl Unpin for NormalizedSelectionKey
impl UnwindSafe for NormalizedSelectionKey
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more