Splits an owned conjunctive [`Expr`] such as `A AND B AND C` => `[A, B, C]` This is often used to "split" filter expressions such as `col1 = 5 AND col2 = 10` into [`col1 = 5`, `col2 = 10`]; # Example ``` # use datafusion_expr::{col, lit}; # use datafusion_expr::utils::split_conjunction_owned; // a=1 AND b=2 let expr = col("a").eq(lit(1)).and(col("b").eq(lit(2))); // [a=1, b=2] let split = vec![
(expr: Expr)
| 1105 | /// assert_eq!(split_conjunction_owned(expr), split); |
| 1106 | /// ``` |
| 1107 | pub fn split_conjunction_owned(expr: Expr) -> Vec<Expr> { |
| 1108 | split_binary_owned(expr, Operator::And) |
| 1109 | } |
| 1110 | |
| 1111 | /// Splits an owned binary operator tree [`Expr`] such as `A <OP> B <OP> C` => `[A, B, C]` |
| 1112 | /// |
no test coverage detected
searching dependent graphs…