sparrow-ipc 0.2.0
Loading...
Searching...
No Matches
magic_values.hpp File Reference
#include <algorithm>
#include <array>
#include <cstdint>
#include <istream>
#include <ranges>
Include dependency graph for magic_values.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  sparrow_ipc
 

Functions

template<std::ranges::input_range R>
bool sparrow_ipc::is_continuation (const R &buf)
 
template<std::ranges::input_range R>
bool sparrow_ipc::is_end_of_stream (const R &buf)
 
template<std::ranges::input_range R>
bool sparrow_ipc::is_arrow_file_magic (const R &buf)
 

Variables

constexpr std::array< std::uint8_t, 4 > sparrow_ipc::continuation = {0xFF, 0xFF, 0xFF, 0xFF}
 Continuation value defined in the Arrow IPC specification: https://arrow.apache.org/docs/format/Columnar.html#encapsulated-message-format.
 
constexpr std::array< std::uint8_t, 8 > sparrow_ipc::end_of_stream = {0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00}
 End-of-stream marker defined in the Arrow IPC specification: https://arrow.apache.org/docs/format/Columnar.html#ipc-streaming-format.
 
constexpr std::array< std::uint8_t, 6 > sparrow_ipc::arrow_file_magic = {'A', 'R', 'R', 'O', 'W', '1'}
 Magic bytes for Arrow file format defined in the Arrow IPC specification: https://arrow.apache.org/docs/format/Columnar.html#ipc-file-format The magic string is "ARROW1" (6 bytes) followed by 2 padding bytes to reach 8-byte alignment.
 
constexpr std::size_t sparrow_ipc::arrow_file_magic_size = arrow_file_magic.size()
 
constexpr std::array< std::uint8_t, 8 > sparrow_ipc::arrow_file_header_magic = {'A', 'R', 'R', 'O', 'W', '1', 0x00, 0x00}
 Magic bytes with padding for file header (8 bytes total for alignment)