pub enum LogicalPlan {
Scan,
Path(Vec<Arc<str>>),
Filter {
input: Box<LogicalPlan>,
pred: Arc<Program>,
},
Project {
input: Box<LogicalPlan>,
map: Arc<Program>,
},
Aggregate {
input: Box<LogicalPlan>,
op: AggOp,
arg: Option<Arc<Program>>,
},
Sort {
input: Box<LogicalPlan>,
key: Option<Arc<Program>>,
desc: bool,
},
Limit {
input: Box<LogicalPlan>,
n: usize,
},
Join {
left: Box<LogicalPlan>,
right: Box<LogicalPlan>,
on: Arc<Program>,
},
Raw(Arc<Program>),
}Variants§
Scan
Root scan — produces the input document.
Path(Vec<Arc<str>>)
Navigate into a field chain from the scan.
Filter
Filter rows by a boolean predicate program.
Project
Project / transform each row.
Aggregate
Aggregate to a single scalar.
Sort
Sort rows.
Limit
Limit / TopN.
Join
Join two plans on matching keys (stubbed — detected but not yet rewritten into a fused execution).
Raw(Arc<Program>)
Opaque fallback: opcode sequence not yet lifted.
Implementations§
Source§impl LogicalPlan
impl LogicalPlan
Sourcepub fn lift(program: &Program) -> LogicalPlan
pub fn lift(program: &Program) -> LogicalPlan
Lift a compiled Program into a LogicalPlan. Best-effort: falls
back to Raw for opcode sequences that don’t fit the relational shape.
Sourcepub fn is_aggregate(&self) -> bool
pub fn is_aggregate(&self) -> bool
True if this plan is a pure aggregate (reduces to scalar).
Trait Implementations§
Source§impl Clone for LogicalPlan
impl Clone for LogicalPlan
Source§fn clone(&self) -> LogicalPlan
fn clone(&self) -> LogicalPlan
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for LogicalPlan
impl RefUnwindSafe for LogicalPlan
impl Send for LogicalPlan
impl Sync for LogicalPlan
impl Unpin for LogicalPlan
impl UnsafeUnpin for LogicalPlan
impl UnwindSafe for LogicalPlan
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