|
| std::pair< std::uint8_t *, int64_t > | get_bitmap_pointer_and_null_count (std::span< const uint8_t > validity_buffer_span, const int64_t length) |
| | Extracts bitmap pointer and null count from a validity buffer span.
|
| |
| std::span< const uint8_t > | get_buffer (const org::apache::arrow::flatbuf::RecordBatch &record_batch, std::span< const uint8_t > body, size_t &buffer_index) |
| | Extracts a buffer from a RecordBatch's body.
|
| |
| std::variant< std::vector< std::uint8_t >, std::span< const std::uint8_t > > | get_decompressed_buffer (std::span< const uint8_t > buffer_span, const org::apache::arrow::flatbuf::BodyCompression *compression) |
| | Retrieves a decompressed buffer or a view of the original buffer.
|
| |
| SPARROW_IPC_API size_t | align_to_8 (const size_t n) |
| |
template<std::ranges::input_range R>
requires std::same_as<std::ranges::range_value_t<R>, sparrow::record_batch> |
| bool | check_record_batches_consistency (const R &record_batches) |
| | Checks if all record batches in a collection have consistent structure.
|
| |
| std::optional< int32_t > | parse_format (std::string_view format_str, std::string_view sep) |
| |
template<std::ranges::input_range R>
requires std::same_as<std::ranges::range_value_t<R>, sparrow::record_batch>
| bool sparrow_ipc::utils::check_record_batches_consistency |
( |
const R & | record_batches | ) |
|
Checks if all record batches in a collection have consistent structure.
This function verifies that all record batches in the provided collection have:
- The same number of columns
- Matching data types for corresponding columns (same column index)
- Template Parameters
-
| R | Container type that holds sparrow::record_batch objects |
- Parameters
-
| record_batches | Collection of record batches to check for consistency |
- Returns
- true if all record batches have consistent structure or if the collection is empty, false if any structural inconsistencies are found
- Note
- An empty collection is considered consistent and returns true
-
The number of rows per record batch is not required to be the same
Definition at line 33 of file utils.hpp.