pub struct LexicographicalComparator { /* private fields */ }
Expand description
A lexicographical comparator that wraps given array data (columns) and can lexicographically compare data at given two indices. The lifetime is the same at the data wrapped.
Implementations§
Source§impl LexicographicalComparator
impl LexicographicalComparator
Sourcepub fn compare(&self, a_idx: usize, b_idx: usize) -> Ordering
pub fn compare(&self, a_idx: usize, b_idx: usize) -> Ordering
lexicographically compare values at the wrapped columns with given indices.
Sourcepub fn try_new(
columns: &[SortColumn],
) -> Result<LexicographicalComparator, ArrowError>
pub fn try_new( columns: &[SortColumn], ) -> Result<LexicographicalComparator, ArrowError>
Create a new lex comparator that will wrap the given sort columns and give comparison results with two indices.
Auto Trait Implementations§
impl Freeze for LexicographicalComparator
impl !RefUnwindSafe for LexicographicalComparator
impl Send for LexicographicalComparator
impl Sync for LexicographicalComparator
impl Unpin for LexicographicalComparator
impl !UnwindSafe for LexicographicalComparator
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