Returns true if all nulls in `other` also exist in self
(&self, other: &NullBuffer)
| 102 | |
| 103 | /// Returns true if all nulls in `other` also exist in self |
| 104 | pub fn contains(&self, other: &NullBuffer) -> bool { |
| 105 | if other.null_count == 0 { |
| 106 | return true; |
| 107 | } |
| 108 | let lhs = self.inner().bit_chunks().iter_padded(); |
| 109 | let rhs = other.inner().bit_chunks().iter_padded(); |
| 110 | lhs.zip(rhs).all(|(l, r)| (l & !r) == 0) |
| 111 | } |
| 112 | |
| 113 | /// Returns a new [`NullBuffer`] where each bit in the current null buffer |
| 114 | /// is repeated `count` times. This is useful for masking the nulls of |
nothing calls this directly
no test coverage detected