[−][src]Trait datafusion::physical_plan::AggregateExpr
An aggregate expression that:
- knows its resulting field
- knows how to create its accumulator
- knows its accumulator's state's field
- knows the expressions from whose its accumulator will receive values
Required methods
fn field(&self) -> Result<Field>
[src]
the field of the final result of this aggregation.
fn create_accumulator(&self) -> Result<Box<dyn Accumulator>>
[src]
the accumulator used to accumulate values from the expressions.
the accumulator expects the same number of arguments as expressions
and must
return states with the same description as state_fields
fn state_fields(&self) -> Result<Vec<Field>>
[src]
the fields that encapsulate the Accumulator's state the number of fields here equals the number of states that the accumulator contains
fn expressions(&self) -> Vec<Arc<dyn PhysicalExpr>>
[src]
expressions that are passed to the Accumulator.
Single-column aggregations such as sum
return a single value, others (e.g. cov
) return many.