pub struct AsyncMapper {
pub async_exprs: Vec<Arc<AsyncFuncExpr>>,
/* private fields */
}Expand description
Maps async_expressions to new columns
The output of the async functions are appended, in order, to the end of the input schema
Fields§
§async_exprs: Vec<Arc<AsyncFuncExpr>>the expressions to map
Implementations§
Source§impl AsyncMapper
impl AsyncMapper
pub fn new(num_input_columns: usize) -> Self
pub fn is_empty(&self) -> bool
pub fn next_column_name(&self) -> String
Sourcepub fn find_references(
&mut self,
physical_expr: &Arc<dyn PhysicalExpr>,
schema: &Schema,
) -> Result<()>
pub fn find_references( &mut self, physical_expr: &Arc<dyn PhysicalExpr>, schema: &Schema, ) -> Result<()>
Finds any references to async functions in the expression and adds them to the map
Sourcepub fn map_expr(
&self,
expr: Arc<dyn PhysicalExpr>,
) -> Transformed<Arc<dyn PhysicalExpr>>
pub fn map_expr( &self, expr: Arc<dyn PhysicalExpr>, ) -> Transformed<Arc<dyn PhysicalExpr>>
If the expression matches any of the async functions, return the new column
Sourcepub fn output_column(&self, idx: usize) -> Arc<dyn PhysicalExpr>
pub fn output_column(&self, idx: usize) -> Arc<dyn PhysicalExpr>
return the output column for the async function at index idx
Trait Implementations§
Auto Trait Implementations§
impl Freeze for AsyncMapper
impl !RefUnwindSafe for AsyncMapper
impl Send for AsyncMapper
impl Sync for AsyncMapper
impl Unpin for AsyncMapper
impl !UnwindSafe for AsyncMapper
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> 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