5#include <CesiumTilesetJson/ClassProperty.h>
6#include <CesiumTilesetJson/Library.h>
7#include <CesiumUtility/ExtensibleObject.h>
11#include <unordered_map>
17struct CESIUMTILESETJSON_API
Class final
22 static constexpr const char*
TypeName =
"Class";
27 std::optional<std::string>
name;
39 std::unordered_map<std::string, CesiumTilesetJson::ClassProperty>
properties;
54 accum += int64_t(
sizeof(
Class));
58 accum += int64_t(this->name->capacity() *
sizeof(
char));
60 if (this->description) {
61 accum += int64_t(this->description->capacity() *
sizeof(
char));
64 this->properties.bucket_count() *
66 for (
const auto& [k, v] : this->properties) {
67 accum += int64_t(k.capacity() *
sizeof(
char) -
sizeof(std::string));
72 accum += int64_t(this->parent->capacity() *
sizeof(
char));
Classes to represent a tileset.json from 3D Tiles 1.1.
A single property of a metadata class.
A class containing a set of properties.
int64_t getSizeBytes() const
Calculates the size in bytes of this object, including the contents of all collections,...
std::optional< std::string > parent
Experimental. The parent class ID.
std::optional< std::string > description
The description of the class.
std::optional< std::string > name
The name of the class, e.g. for display purposes.
std::unordered_map< std::string, CesiumTilesetJson::ClassProperty > properties
A dictionary, where each key is a property ID and each value is an object defining the property....
static constexpr const char * TypeName
The original name of this type.
The base class for objects that have extensions and extras.
int64_t getSizeBytes() const
Calculates the size in bytes of this ExtensibleObject, including all of its extras but NOT including ...