Skip to main content

CommandBufferTypeId.ixx File

Unique type identifier for command buffers. More...

Included Headers

#include <functional> #include <cstddef> #include <helios.ecs.types> #include <helios.ecs.TypeIndexer>

Namespaces Index

namespacehelios
namespaceengine
namespaceruntime
namespacemessaging
namespacecommand
namespacetypes

Classes Index

classCommandBufferTypeId

Unique type identifier for command buffer types. More...

structhelios_engine_common_tag_CommandTypes

Tag type for the TypeIndexer domain. More...

structhash<helios::engine::runtime::messaging::command::types::CommandBufferTypeId>

Hash specialization for CommandBufferTypeId. More...

Description

Unique type identifier for command buffers.

File Listing

The file content with the documentation metadata removed is:

1
5module;
6
7#include <functional>
8#include <cstddef>
9
10export module helios.engine.runtime.messaging.command.types.CommandBufferTypeId;
11
12import helios.ecs.TypeIndexer;
13import helios.ecs.types;
14
16
31
35 struct helios_engine_common_tag_CommandTypes{};
36
37 using ComponentType = helios_engine_common_tag_CommandTypes;
38
42 size_t id_{0};
43
44
45 public:
46
47
53 explicit CommandBufferTypeId(const size_t id) : id_(id) {}
54
55
61 explicit CommandBufferTypeId(helios::ecs::types::no_init_t) {}
62
63
70 return id_;
71 }
72
73
84 template <typename T>
86 static const size_t tid = helios::ecs::TypeIndexer<ComponentType>::typeIndex<T>();
88 }
89
90 friend constexpr bool operator==(CommandBufferTypeId, CommandBufferTypeId) noexcept = default;
91 };
92
93
94}
95
96
100template<>
101struct std::hash<helios::engine::runtime::messaging::command::types::CommandBufferTypeId> {
103 return id.value();
104 }
105
106};

Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.9.8.