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

Function bool_test_arrays

datafusion/physical-expr/src/expressions/binary.rs:3029–3061  ·  view source on GitHub ↗

Returns (schema, a: BooleanArray, b: BooleanArray) with all possible inputs a: [true, true, true, NULL, NULL, NULL, false, false, false] b: [true, NULL, false, true, NULL, false, true, NULL, false]

()

Source from the content-addressed store, hash-verified

3027 /// a: [true, true, true, NULL, NULL, NULL, false, false, false]
3028 /// b: [true, NULL, false, true, NULL, false, true, NULL, false]
3029 fn bool_test_arrays() -> (SchemaRef, ArrayRef, ArrayRef) {
3030 let schema = Schema::new(vec![
3031 Field::new("a", DataType::Boolean, true),
3032 Field::new("b", DataType::Boolean, true),
3033 ]);
3034 let a: BooleanArray = [
3035 Some(true),
3036 Some(true),
3037 Some(true),
3038 None,
3039 None,
3040 None,
3041 Some(false),
3042 Some(false),
3043 Some(false),
3044 ]
3045 .iter()
3046 .collect();
3047 let b: BooleanArray = [
3048 Some(true),
3049 None,
3050 Some(false),
3051 Some(true),
3052 None,
3053 Some(false),
3054 Some(true),
3055 None,
3056 Some(false),
3057 ]
3058 .iter()
3059 .collect();
3060 (Arc::new(schema), Arc::new(a), Arc::new(b))
3061 }
3062
3063 /// Returns (schema, BooleanArray) with [true, NULL, false]
3064 fn scalar_bool_test_array() -> (SchemaRef, ArrayRef) {

Callers 8

eq_op_boolFunction · 0.85
neq_op_boolFunction · 0.85
lt_op_boolFunction · 0.85
lt_eq_op_boolFunction · 0.85
gt_op_boolFunction · 0.85
gt_eq_op_boolFunction · 0.85
is_distinct_from_op_boolFunction · 0.85

Calls 3

newFunction · 0.85
collectMethod · 0.80
iterMethod · 0.45

Tested by 8

eq_op_boolFunction · 0.68
neq_op_boolFunction · 0.68
lt_op_boolFunction · 0.68
lt_eq_op_boolFunction · 0.68
gt_op_boolFunction · 0.68
gt_eq_op_boolFunction · 0.68
is_distinct_from_op_boolFunction · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…