MCPcopy Create free account
hub / github.com/TileDB-Inc/TileDB / Object

Class Object

tiledb/sm/cpp_api/object.h:54–217  ·  view source on GitHub ↗

* Represents a TileDB object: array, group, key-value (map), or none * (invalid). */

Source from the content-addressed store, hash-verified

52 * (invalid).
53 */
54class Object {
55 public:
56 /* ********************************* */
57 /* TYPE DEFINITIONS */
58 /* ********************************* */
59
60 /** The object type. */
61 enum class Type {
62 /** TileDB array object. */
63 Array,
64 /** TileDB group object. */
65 Group,
66 /** Invalid or unknown object type. */
67 Invalid
68 };
69
70 /* ********************************* */
71 /* CONSTRUCTORS & DESTRUCTORS */
72 /* ********************************* */
73
74 explicit Object(
75 const Type& type,
76 const std::string& uri = "",
77 const std::optional<std::string>& name = std::nullopt)
78 : type_(type)
79 , uri_(uri)
80 , name_(name) {
81 }
82
83 explicit Object(
84 tiledb_object_t type,
85 const std::string& uri = "",
86 const std::optional<std::string>& name = std::nullopt)
87 : uri_(uri)
88 , name_(name) {
89 switch (type) {
90 case TILEDB_ARRAY:
91 type_ = Type::Array;
92 break;
93 case TILEDB_GROUP:
94 type_ = Type::Group;
95 break;
96 case TILEDB_INVALID:
97 type_ = Type::Invalid;
98 break;
99 }
100 }
101
102 Object() = default;
103 Object(const Object&) = default;
104 Object(Object&&) = default;
105 Object& operator=(const Object&) = default;
106 Object& operator=(Object&&) = default;
107
108 /* ********************************* */
109 /* API */
110 /* ********************************* */
111

Callers 3

memberMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected