// DO NOT EDIT! This file was auto-generated by crates/re_types_builder/src/codegen/cpp/mod.rs
// Based on "crates/re_types/definitions/rerun/blueprint/components/auto_space_views.fbs".

#pragma once

#include "../../result.hpp"

#include <cstdint>
#include <memory>

namespace arrow {
    class Array;
    class BooleanBuilder;
    class DataType;
} // namespace arrow

namespace rerun::blueprint::components {
    /// **Component**: Whether or not space views should be created automatically.
    struct AutoSpaceViews {
        bool auto_space_views;

      public:
        AutoSpaceViews() = default;

        AutoSpaceViews(bool auto_space_views_) : auto_space_views(auto_space_views_) {}

        AutoSpaceViews& operator=(bool auto_space_views_) {
            auto_space_views = auto_space_views_;
            return *this;
        }
    };
} // namespace rerun::blueprint::components

namespace rerun {
    template <typename T>
    struct Loggable;

    /// \private
    template <>
    struct Loggable<blueprint::components::AutoSpaceViews> {
        static constexpr const char Name[] = "rerun.blueprint.components.AutoSpaceViews";

        /// Returns the arrow data type this type corresponds to.
        static const std::shared_ptr<arrow::DataType>& arrow_datatype();

        /// Serializes an array of `rerun::blueprint:: components::AutoSpaceViews` into an arrow array.
        static Result<std::shared_ptr<arrow::Array>> to_arrow(
            const blueprint::components::AutoSpaceViews* instances, size_t num_instances
        );

        /// Fills an arrow array builder with an array of this type.
        static rerun::Error fill_arrow_array_builder(
            arrow::BooleanBuilder* builder, const blueprint::components::AutoSpaceViews* elements,
            size_t num_elements
        );
    };
} // namespace rerun
