Struct lance_datafusion::projection::ProjectionPlan
source · pub struct ProjectionPlan {
pub physical_schema: Arc<Schema>,
pub physical_df_schema: Arc<DFSchema>,
pub requested_output_expr: Option<Vec<(Expr, String)>>,
}Fields§
§physical_schema: Arc<Schema>The physical schema (before dynamic projection) that must be loaded from the dataset
physical_df_schema: Arc<DFSchema>§requested_output_expr: Option<Vec<(Expr, String)>>The expressions for all the columns to be in the output Note: this doesn’t include _distance, and _rowid
Implementations§
source§impl ProjectionPlan
impl ProjectionPlan
pub fn try_new( base_schema: &Schema, columns: &[(impl AsRef<str>, impl AsRef<str>)], ) -> Result<Self>
pub fn new_empty(base_schema: Arc<Schema>) -> Self
pub fn arrow_schema(&self) -> &ArrowSchema
pub fn arrow_schema_ref(&self) -> SchemaRef
pub fn to_physical_exprs(&self) -> Result<Vec<(Arc<dyn PhysicalExpr>, String)>>
pub fn output_schema(&self) -> Result<ArrowSchema>
pub async fn project_batch(&self, batch: RecordBatch) -> Result<RecordBatch>
pub fn project_stream( &self, stream: SendableRecordBatchStream, ) -> Result<SendableRecordBatchStream>
Auto Trait Implementations§
impl Freeze for ProjectionPlan
impl !RefUnwindSafe for ProjectionPlan
impl Send for ProjectionPlan
impl Sync for ProjectionPlan
impl Unpin for ProjectionPlan
impl !UnwindSafe for ProjectionPlan
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> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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