1#ifndef LIBSBX_UTILITY_TYPE_ID_HPP_
2#define LIBSBX_UTILITY_TYPE_ID_HPP_
7namespace sbx::utility {
11template<
typename Scope>
13 [[nodiscard]]
static auto next()
noexcept -> std::uint32_t {
14 static auto id = std::uint32_t{};
29template<
typename Scope,
typename Type>
40 [[nodiscard]]
static auto value() noexcept -> std::uint32_t {
46 [[nodiscard]]
constexpr operator std::uint32_t() const noexcept {
57template<
typename Type>
58using type_id = scoped_type_id<detail::default_type_id_scope, Type>;
Definition: type_id.hpp:19
Definition: type_id.hpp:12
A scoped type ID generator. Allows for generating unique IDs for types within a specific scope.
Definition: type_id.hpp:30
static auto value() noexcept -> std::uint32_t
Generates a unique ID for the type.
Definition: type_id.hpp:40