Enum datafusion_expr::Volatility
source · pub enum Volatility {
Immutable,
Stable,
Volatile,
}
Expand description
A function’s volatility, which defines the functions eligibility for certain optimizations
Variants§
Immutable
Immutable - An immutable function will always return the same output when given the same input. An example of this is super::BuiltinScalarFunction::Cos.
Stable
Stable - A stable function may return different values given the same input across different queries but must return the same value for a given input within a query. An example of this is super::BuiltinScalarFunction::Now.
Volatile
Volatile - A volatile function may change the return value from evaluation to evaluation. Multiple invocations of a volatile function may return different results when used in the same query. An example of this is super::BuiltinScalarFunction::Random.
Trait Implementations§
source§impl Clone for Volatility
impl Clone for Volatility
source§fn clone(&self) -> Volatility
fn clone(&self) -> Volatility
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 moresource§impl Debug for Volatility
impl Debug for Volatility
source§impl Hash for Volatility
impl Hash for Volatility
source§impl Ord for Volatility
impl Ord for Volatility
source§fn cmp(&self, other: &Volatility) -> Ordering
fn cmp(&self, other: &Volatility) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq<Volatility> for Volatility
impl PartialEq<Volatility> for Volatility
source§fn eq(&self, other: &Volatility) -> bool
fn eq(&self, other: &Volatility) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd<Volatility> for Volatility
impl PartialOrd<Volatility> for Volatility
source§fn partial_cmp(&self, other: &Volatility) -> Option<Ordering>
fn partial_cmp(&self, other: &Volatility) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for Volatility
impl Eq for Volatility
impl StructuralEq for Volatility
impl StructuralPartialEq for Volatility
Auto Trait Implementations§
impl RefUnwindSafe for Volatility
impl Send for Volatility
impl Sync for Volatility
impl Unpin for Volatility
impl UnwindSafe for Volatility
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
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.