Struct arrow::compute::LexicographicalComparator
source · pub struct LexicographicalComparator<'a> { /* 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.