29#include <unordered_map>
44 std::shared_ptr<Schema> schema;
45 std::shared_ptr<PartitionSpec> spec;
47 FileFormatType format = FileFormatType::kParquet;
48 std::shared_ptr<FileIO> io;
49 std::optional<int32_t> sort_order_id;
50 std::unordered_map<std::string, std::string> properties;
68 std::unique_ptr<Impl> impl_;
70 explicit DataWriter(std::unique_ptr<Impl> impl);
Writer for Iceberg data files.
Definition data_writer.h:54
Result< int64_t > Length() const override
Get the current number of bytes written.
Result< WriteResult > Metadata() override
Get file metadata for all files produced by this writer.
Status Write(ArrowArray *data) override
Write a batch of records.
static Result< std::unique_ptr< DataWriter > > Make(const DataWriterOptions &options)
Create a new DataWriter instance.
Status Close() override
Close the writer and finalize the file.
Base interface for data file writers.
Definition writer.h:50
StructLike wrapper for a vector of literals that represent partition values.
Definition partition_values.h:36
Define symbol visibility macros for data APIs.
Core Apache Iceberg C++ APIs.
Definition arrow_io_util.h:33
std::expected< T, E > Result
Result alias.
Definition result.h:88
Define Result, Status, and error helpers.
Definition arrow_c_data.h:57
Options for creating a DataWriter.
Definition data_writer.h:42