MCPcopy Create free account
hub / github.com/apache/datafusion / state

Method state

datafusion/functions-aggregate/src/average.rs:538–543  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

536 }
537
538 fn state(&mut self) -> Result<Vec<ScalarValue>> {
539 Ok(vec![
540 ScalarValue::from(self.count),
541 ScalarValue::Float64(self.sum),
542 ])
543 }
544
545 fn merge_batch(&mut self, states: &[ArrayRef]) -> Result<()> {
546 // counts are summed

Callers

nothing calls this directly

Calls 6

newFunction · 0.85
take_neededMethod · 0.80
with_data_typeMethod · 0.80
buildMethod · 0.45
intoMethod · 0.45
cloneMethod · 0.45

Tested by

no test coverage detected