Skip to content

Commit

Permalink
Add TableChangesScan::schema method to get logical schema (#589)
Browse files Browse the repository at this point in the history
## What changes are proposed in this pull request?
This PR adds a pub method to fetch the logical schema of a
`TableChangesScan`


## How was this change tested?
Everything compiles.
  • Loading branch information
OussamaSaoudi-db authored Dec 11, 2024
1 parent 04ccccb commit be1453f
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion kernel/src/table_changes/scan.rs
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,14 @@ impl TableChangesScan {
}
}

/// Get the predicate [`Expression`] of the scan.
/// Get a shared reference to the [`Schema`] of the table changes scan.
///
/// [`Schema`]: crate::schema::Schema
pub fn schema(&self) -> &SchemaRef {
&self.logical_schema
}

/// Get the predicate [`ExpressionRef`] of the scan.
fn physical_predicate(&self) -> Option<ExpressionRef> {
if let PhysicalPredicate::Some(ref predicate, _) = self.physical_predicate {
Some(predicate.clone())
Expand Down

0 comments on commit be1453f

Please sign in to comment.