pub struct RetainedScalarLiteral(/* private fields */);Expand description
Selected result metadata shared with an already evaluated datum. Plan copies never duplicate its allocation or change its constructor lease.
Implementations§
Source§impl RetainedScalarLiteral
impl RetainedScalarLiteral
Sourcepub fn has_same_representation_with_control(
&self,
other: &Self,
control: &ProductionControl<'_>,
) -> Result<bool, SQLError>
pub fn has_same_representation_with_control( &self, other: &Self, control: &ProductionControl<'_>, ) -> Result<bool, SQLError>
Compare the exact retained value and metadata with admission for independent spilled reads. Semantic read failures conservatively decline equality; resource failures remain observable errors.
Source§impl RetainedScalarLiteral
impl RetainedScalarLiteral
pub fn new( value: RetainedConstantValue, ty: Option<ColumnType>, declaration: Option<String>, collation_oid: Option<u32>, ) -> Self
Sourcepub fn with_control(
value: RetainedConstantValue,
ty: Option<Produced<ColumnType>>,
declaration: Option<Produced<String>>,
collation_oid: Option<u32>,
control: &ProductionControl<'_>,
) -> Result<Self, SQLError>
pub fn with_control( value: RetainedConstantValue, ty: Option<Produced<ColumnType>>, declaration: Option<Produced<String>>, collation_oid: Option<u32>, control: &ProductionControl<'_>, ) -> Result<Self, SQLError>
The value source retains its own storage lease. Metadata constructors supply their existing leases and this owner admits the shared header before allocation.
Sourcepub fn materialize(&self) -> Result<ScalarExpr, SQLError>
pub fn materialize(&self) -> Result<ScalarExpr, SQLError>
Materialize one value only at an interface that requires an owned literal. Cloning plans retains the shared owner instead.
Trait Implementations§
Source§impl Clone for RetainedScalarLiteral
impl Clone for RetainedScalarLiteral
Source§impl Debug for RetainedScalarLiteral
impl Debug for RetainedScalarLiteral
Source§impl Deref for RetainedScalarLiteral
impl Deref for RetainedScalarLiteral
Source§impl ObserveAllocations for RetainedScalarLiteral
impl ObserveAllocations for RetainedScalarLiteral
fn observe_allocations<'a>( &'a self, observer: &mut AllocationObserver<'a, '_>, ) -> Result<(), ValueRetentionError>
Source§impl PartialEq for RetainedScalarLiteral
impl PartialEq for RetainedScalarLiteral
Source§impl Serialize for RetainedScalarLiteral
impl Serialize for RetainedScalarLiteral
impl StructuralPartialEq for RetainedScalarLiteral
Auto Trait Implementations§
impl !RefUnwindSafe for RetainedScalarLiteral
impl !UnwindSafe for RetainedScalarLiteral
impl Freeze for RetainedScalarLiteral
impl Send for RetainedScalarLiteral
impl Sync for RetainedScalarLiteral
impl Unpin for RetainedScalarLiteral
impl UnsafeUnpin for RetainedScalarLiteral
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more