Prepend a validity bitmap to compressed data.
(valid: &[bool], compressed: &[u8])
| 41 | |
| 42 | /// Prepend a validity bitmap to compressed data. |
| 43 | pub(super) fn prepend_validity(valid: &[bool], compressed: &[u8]) -> Vec<u8> { |
| 44 | let bitmap = encode_validity_bitmap(valid); |
| 45 | let mut result = Vec::with_capacity(bitmap.len() + compressed.len()); |
| 46 | result.extend_from_slice(&bitmap); |
| 47 | result.extend_from_slice(compressed); |
| 48 | result |
| 49 | } |
| 50 | |
| 51 | /// Compute a simple schema hash for the footer. |
| 52 | pub(super) fn compute_schema_hash(schema: &ColumnarSchema) -> u64 { |
no test coverage detected