pub trait AggregationMonoid: Send + Sync {
// Required methods
fn identity(&self) -> AggState;
fn accumulate(
&self,
state: AggState,
value: &Value,
) -> StorageBackendResult<AggState>;
fn combine(
&self,
a: AggState,
b: AggState,
) -> StorageBackendResult<AggState>;
fn finalize(&self, state: AggState) -> StorageBackendResult<Value>;
}Expand description
Aggregation function with monoid structure for parallel decomposition. See Section 5.1, Paper 1.
Required Methods§
fn identity(&self) -> AggState
fn accumulate( &self, state: AggState, value: &Value, ) -> StorageBackendResult<AggState>
fn combine(&self, a: AggState, b: AggState) -> StorageBackendResult<AggState>
fn finalize(&self, state: AggState) -> StorageBackendResult<Value>
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".