MCPcopy Create free account
hub / github.com/apache/datafusion / try_pushdown_projection

Method try_pushdown_projection

datafusion/datasource/src/test_util.rs:109–121  ·  view source on GitHub ↗
(
        &self,
        projection: &datafusion_physical_plan::projection::ProjectionExprs,
    )

Source from the content-addressed store, hash-verified

107 }
108
109 fn try_pushdown_projection(
110 &self,
111 projection: &datafusion_physical_plan::projection::ProjectionExprs,
112 ) -> Result<Option<Arc<dyn FileSource>>> {
113 let mut source = self.clone();
114 let new_projection = self.projection.source.try_merge(projection)?;
115 let split_projection = crate::projection::SplitProjection::new(
116 self.table_schema.file_schema(),
117 &new_projection,
118 );
119 source.projection = split_projection;
120 Ok(Some(Arc::new(source)))
121 }
122
123 fn projection(
124 &self,

Calls 4

newFunction · 0.85
try_mergeMethod · 0.80
cloneMethod · 0.45
file_schemaMethod · 0.45

Tested by

no test coverage detected