pub struct OperationMetadata {
pub name: &'static str,
pub cse_key: Option<Box<str>>,
pub cost: Cost,
pub estimated_output_bytes: usize,
pub uses_spatial_index: bool,
}Expand description
Static information used by compilation, explanation and memory admission.
Fields§
§name: &'static strCanonical operation name shown by explain.
cse_key: Option<Box<str>>Stable semantic key. Equal keys and equal dependencies are CSE candidates.
cost: CostDominant data-movement cost.
estimated_output_bytes: usizeConservative bytes retained by the operation result.
uses_spatial_index: boolWhether the operation needs a reusable spatial index.
Implementations§
Source§impl OperationMetadata
impl OperationMetadata
Sourcepub const fn new(name: &'static str, cost: Cost) -> Self
pub const fn new(name: &'static str, cost: Cost) -> Self
Metadata for an operation without a semantic CSE key.
Sourcepub fn with_cse_key(self, key: impl Into<Box<str>>) -> Self
pub fn with_cse_key(self, key: impl Into<Box<str>>) -> Self
Adds a stable key used for common-subexpression elimination.
Sourcepub const fn with_estimated_output_bytes(self, bytes: usize) -> Self
pub const fn with_estimated_output_bytes(self, bytes: usize) -> Self
Adds a conservative retained-size estimate.
Sourcepub const fn with_spatial_index(self) -> Self
pub const fn with_spatial_index(self) -> Self
Marks an operation as a spatial-index consumer.
Trait Implementations§
Source§impl Clone for OperationMetadata
impl Clone for OperationMetadata
Source§impl Debug for OperationMetadata
impl Debug for OperationMetadata
impl Eq for OperationMetadata
Source§impl PartialEq for OperationMetadata
impl PartialEq for OperationMetadata
impl StructuralPartialEq for OperationMetadata
Auto Trait Implementations§
impl Freeze for OperationMetadata
impl RefUnwindSafe for OperationMetadata
impl Send for OperationMetadata
impl Sync for OperationMetadata
impl Unpin for OperationMetadata
impl UnsafeUnpin for OperationMetadata
impl UnwindSafe for OperationMetadata
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,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.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