Rerun C++ SDK
Loading...
Searching...
No Matches
bool.hpp
1// DO NOT EDIT! This file was auto-generated by crates/build/re_types_builder/src/codegen/cpp/mod.rs
2// Based on "crates/store/re_types/definitions/rerun/datatypes/bool.fbs".
3
4#pragma once
5
6#include "../result.hpp"
7
8#include <cstdint>
9#include <memory>
10
11namespace arrow {
12 class Array;
13 class BooleanBuilder;
14 class DataType;
15} // namespace arrow
16
17namespace rerun::datatypes {
18 /// **Datatype**: A single boolean.
19 struct Bool {
20 bool value;
21
22 public:
23 Bool() = default;
24
25 Bool(bool value_) : value(value_) {}
26
27 Bool& operator=(bool value_) {
28 value = value_;
29 return *this;
30 }
31 };
32} // namespace rerun::datatypes
33
34namespace rerun {
35 template <typename T>
36 struct Loggable;
37
38 /// \private
39 template <>
40 struct Loggable<datatypes::Bool> {
41 static constexpr const char Name[] = "rerun.datatypes.Bool";
42
43 /// Returns the arrow data type this type corresponds to.
44 static const std::shared_ptr<arrow::DataType>& arrow_datatype();
45
46 /// Serializes an array of `rerun::datatypes::Bool` into an arrow array.
48 const datatypes::Bool* instances, size_t num_instances
49 );
50
51 /// Fills an arrow array builder with an array of this type.
52 static rerun::Error fill_arrow_array_builder(
53 arrow::BooleanBuilder* builder, const datatypes::Bool* elements, size_t num_elements
54 );
55 };
56} // namespace rerun
Status outcome object (success or error) returned for fallible operations.
Definition error.hpp:91
A class for representing either a usable value, or an error.
Definition result.hpp:14
All built-in datatypes. See Types in the Rerun manual.
Definition rerun.hpp:78
All Rerun C++ types and functions are in the rerun namespace or one of its nested namespaces.
Definition rerun.hpp:22
The Loggable trait is used by all built-in implementation of rerun::AsComponents to serialize a colle...
Definition loggable.hpp:11
Datatype: A single boolean.
Definition bool.hpp:19