pub enum ScalarQueryConstancy {
Constant,
SlowChanging,
Volatile,
}Expand description
Frozen policy governing whether a scalar call is constant for one query.
This is distinct from ScalarSchemaSafety: SQLite’s slow-changing
built-ins are stable for one statement and can therefore be factored out of
inner loops, but they are not safe in schema-maintained expressions. The
registry derives this metadata from public deterministic registration APIs;
only sealed, crate-private built-in registration paths can publish
Self::SlowChanging.
Variants§
Constant
With identical arguments, the function is stable across statements.
SlowChanging
The function is stable during one query but may change between them.
Volatile
The function may produce a different result on every invocation.
Implementations§
Source§impl ScalarQueryConstancy
impl ScalarQueryConstancy
Sourcepub const fn is_query_constant(self) -> bool
pub const fn is_query_constant(self) -> bool
Whether the function is stable for the duration of one query.
Trait Implementations§
Source§impl Clone for ScalarQueryConstancy
impl Clone for ScalarQueryConstancy
Source§fn clone(&self) -> ScalarQueryConstancy
fn clone(&self) -> ScalarQueryConstancy
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for ScalarQueryConstancy
Source§impl Debug for ScalarQueryConstancy
impl Debug for ScalarQueryConstancy
impl Eq for ScalarQueryConstancy
Source§impl PartialEq for ScalarQueryConstancy
impl PartialEq for ScalarQueryConstancy
impl StructuralPartialEq for ScalarQueryConstancy
Auto Trait Implementations§
impl Freeze for ScalarQueryConstancy
impl RefUnwindSafe for ScalarQueryConstancy
impl Send for ScalarQueryConstancy
impl Sync for ScalarQueryConstancy
impl Unpin for ScalarQueryConstancy
impl UnsafeUnpin for ScalarQueryConstancy
impl UnwindSafe for ScalarQueryConstancy
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