pub struct ExecutionProps {
pub query_execution_start_time: DateTime<Utc>,
pub alias_generator: Arc<AliasGenerator>,
pub var_providers: Option<HashMap<VarType, Arc<dyn VarProvider + Send + Sync>>>,
}
Expand description
Holds per-query execution properties and data (such as statement starting timestamps).
An ExecutionProps
is created each time a LogicalPlan
is
prepared for execution (optimized). If the same plan is optimized
multiple times, a new ExecutionProps
is created each time.
It is important that this structure be cheap to create as it is done so during predicate pruning and expression simplification
Fields§
§query_execution_start_time: DateTime<Utc>
§alias_generator: Arc<AliasGenerator>
Alias generator used by subquery optimizer rules
var_providers: Option<HashMap<VarType, Arc<dyn VarProvider + Send + Sync>>>
Providers for scalar variables
Implementations§
Source§impl ExecutionProps
impl ExecutionProps
Sourcepub fn new() -> ExecutionProps
pub fn new() -> ExecutionProps
Creates a new execution props
Sourcepub fn with_query_execution_start_time(
self,
query_execution_start_time: DateTime<Utc>,
) -> ExecutionProps
pub fn with_query_execution_start_time( self, query_execution_start_time: DateTime<Utc>, ) -> ExecutionProps
Set the query execution start time to use
Sourcepub fn start_execution(&mut self) -> &ExecutionProps
pub fn start_execution(&mut self) -> &ExecutionProps
Marks the execution of query started timestamp. This also instantiates a new alias generator.
Sourcepub fn add_var_provider(
&mut self,
var_type: VarType,
provider: Arc<dyn VarProvider + Send + Sync>,
) -> Option<Arc<dyn VarProvider + Send + Sync>>
pub fn add_var_provider( &mut self, var_type: VarType, provider: Arc<dyn VarProvider + Send + Sync>, ) -> Option<Arc<dyn VarProvider + Send + Sync>>
Registers a variable provider, returning the existing provider, if any
Sourcepub fn get_var_provider(
&self,
var_type: VarType,
) -> Option<Arc<dyn VarProvider + Send + Sync>>
pub fn get_var_provider( &self, var_type: VarType, ) -> Option<Arc<dyn VarProvider + Send + Sync>>
Returns the provider for the var_type
, if any
Trait Implementations§
Source§impl Clone for ExecutionProps
impl Clone for ExecutionProps
Source§fn clone(&self) -> ExecutionProps
fn clone(&self) -> ExecutionProps
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 ExecutionProps
impl Debug for ExecutionProps
Source§impl Default for ExecutionProps
impl Default for ExecutionProps
Source§fn default() -> ExecutionProps
fn default() -> ExecutionProps
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ExecutionProps
impl !RefUnwindSafe for ExecutionProps
impl Send for ExecutionProps
impl Sync for ExecutionProps
impl Unpin for ExecutionProps
impl !UnwindSafe for ExecutionProps
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)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