Type Alias datafusion_physical_expr::equivalence::OrderingEquivalentClass
source · pub type OrderingEquivalentClass = EquivalentClass<LexOrdering>;
Expand description
LexOrdering
stores the lexicographical ordering for a schema.
OrderingEquivalentClass keeps track of different alternative orderings than can
describe the schema.
For instance, for the table below
|a|b|c|d|
|1|4|3|1|
|2|3|3|2|
|3|1|2|2|
|3|2|1|3|
both vec![a ASC, b ASC]
and vec![c DESC, d ASC]
describe the ordering of the table.
For this case, we say that vec![a ASC, b ASC]
, and vec![c DESC, d ASC]
are ordering equivalent.
Aliased Type§
struct OrderingEquivalentClass { /* private fields */ }
Implementations§
source§impl<T: Eq + Hash + Clone> EquivalentClass<T>
impl<T: Eq + Hash + Clone> EquivalentClass<T>
pub fn new(head: T, others: Vec<T>) -> EquivalentClass<T>
pub fn head(&self) -> &T
pub fn others(&self) -> &HashSet<T>
pub fn contains(&self, col: &T) -> bool
pub fn insert(&mut self, col: T) -> bool
pub fn remove(&mut self, col: &T) -> bool
pub fn iter(&self) -> impl Iterator<Item = &T>
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
Trait Implementations§
source§impl<T: Clone> Clone for EquivalentClass<T>
impl<T: Clone> Clone for EquivalentClass<T>
source§fn clone(&self) -> EquivalentClass<T>
fn clone(&self) -> EquivalentClass<T>
Returns a copy 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 more