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

Method output_ordering

datafusion/functions/src/math/trunc.rs:154–167  ·  view source on GitHub ↗
(&self, input: &[ExprProperties])

Source from the content-addressed store, hash-verified

152 }
153
154 fn output_ordering(&self, input: &[ExprProperties]) -> Result<SortProperties> {
155 // trunc preserves the order of the first argument
156 let value = &input[0];
157 let precision = input.get(1);
158
159 if precision
160 .map(|r| r.sort_properties.eq(&SortProperties::Singleton))
161 .unwrap_or(true)
162 {
163 Ok(value.sort_properties)
164 } else {
165 Ok(SortProperties::Unordered)
166 }
167 }
168
169 fn documentation(&self) -> Option<&Documentation> {
170 self.doc()

Callers

nothing calls this directly

Calls 3

getMethod · 0.45
mapMethod · 0.45
eqMethod · 0.45

Tested by

no test coverage detected