pub trait DynAggregatorFactory: Send + Sync {
// Required methods
fn create_accumulator(&self) -> Box<dyn DynAccumulator>;
fn result_field(&self) -> Field;
fn clone_box(&self) -> Box<dyn DynAggregatorFactory>;
fn type_tag(&self) -> &'static str;
}Expand description
Factory trait for creating DynAccumulator instances.
Each factory corresponds to one aggregate function (e.g., SUM, COUNT).
The CompositeAggregator holds multiple factories.
Required Methods§
Sourcefn create_accumulator(&self) -> Box<dyn DynAccumulator>
fn create_accumulator(&self) -> Box<dyn DynAccumulator>
Creates a new empty accumulator.
Sourcefn result_field(&self) -> Field
fn result_field(&self) -> Field
Returns the Arrow field descriptor for results.
Sourcefn clone_box(&self) -> Box<dyn DynAggregatorFactory>
fn clone_box(&self) -> Box<dyn DynAggregatorFactory>
Creates a boxed clone of this factory.