Skip to content

Commit

Permalink
expose more internals
Browse files Browse the repository at this point in the history
  • Loading branch information
yihozhang committed Nov 18, 2024
1 parent 6bd6b17 commit bdf7a46
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
9 changes: 8 additions & 1 deletion src/function/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ pub struct Function {
pub(crate) decl: ResolvedFunctionDecl,
pub schema: ResolvedSchema,
pub merge: MergeAction,
pub(crate) nodes: table::Table,
pub nodes: table::Table,
sorts: HashSet<Symbol>,
pub(crate) indexes: Vec<Rc<ColumnIndex>>,
pub(crate) rebuild_indexes: Vec<Option<CompositeColumnIndex>>,
Expand Down Expand Up @@ -491,4 +491,11 @@ impl Function {
pub fn is_extractable(&self) -> bool {
!self.decl.unextractable
}

pub fn iter(
&self,
include_subsumed: bool,
) -> impl Iterator<Item = (&[Value], &TupleOutput)> + '_ {
self.nodes.iter(include_subsumed)
}
}
4 changes: 2 additions & 2 deletions src/function/table.rs
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ struct TableOffset {
}

#[derive(Default, Clone)]
pub(crate) struct Table {
pub struct Table {
max_ts: u32,
n_stale: usize,
table: RawTable<TableOffset>,
Expand Down Expand Up @@ -262,7 +262,7 @@ impl Table {
}

/// Iterate over the live entries in the table, in insertion order.
pub(crate) fn iter(
pub fn iter(
&self,
include_subsumed: bool,
) -> impl Iterator<Item = (&[Value], &TupleOutput)> + '_ {
Expand Down

0 comments on commit bdf7a46

Please sign in to comment.