sparrow-ipc 0.2.0
Loading...
Searching...
No Matches
deserialize_duration_array.hpp
Go to the documentation of this file.
1#pragma once
2
3#include <optional>
4#include <span>
5#include <string_view>
6#include <vector>
7
8#include <sparrow/arrow_interface/arrow_array_schema_proxy.hpp>
9#include <sparrow/duration_array.hpp>
10
11#include "Message_generated.h"
13
14namespace sparrow_ipc
15{
16 template <typename T>
17 [[nodiscard]] sparrow::duration_array<T> deserialize_non_owning_duration_array(
18 const org::apache::arrow::flatbuf::RecordBatch& record_batch,
19 std::span<const uint8_t> body,
20 std::string_view name,
21 const std::optional<std::vector<sparrow::metadata_pair>>& metadata,
22 bool nullable,
23 size_t& buffer_index
24 )
25 {
27 record_batch,
28 body,
29 name,
30 metadata,
31 nullable,
32 buffer_index
33 );
34 }
35}
ArrayType< T > deserialize_non_owning_simple_array(const org::apache::arrow::flatbuf::RecordBatch &record_batch, std::span< const uint8_t > body, std::string_view name, const std::optional< std::vector< sparrow::metadata_pair > > &metadata, bool nullable, size_t &buffer_index, std::optional< std::string > format_override=std::nullopt)
Generic implementation for deserializing non-owning arrays with simple layout.
sparrow::duration_array< T > deserialize_non_owning_duration_array(const org::apache::arrow::flatbuf::RecordBatch &record_batch, std::span< const uint8_t > body, std::string_view name, const std::optional< std::vector< sparrow::metadata_pair > > &metadata, bool nullable, size_t &buffer_index)