1 #ifndef ENTT_ENTITY_ENTITY_HPP
2 #define ENTT_ENTITY_ENTITY_HPP
8 #include "../config/config.h"
20 template<
typename,
typename =
void>
28 template<
typename Type>
29 struct entt_traits<Type, std::enable_if_t<std::is_enum_v<Type>>>
56 static constexpr std::size_t entity_shift = 12u;
82 static constexpr std::size_t entity_shift = 20u;
108 static constexpr std::size_t entity_shift = 32u;
118 template<
typename Entity>
131 template<
typename Entity>
132 [[nodiscard]] constexpr
operator Entity() const ENTT_NOEXCEPT {
158 template<
typename Entity>
169 template<
typename Entity>
171 return !(
entity == *
this);
183 template<
typename Entity>
185 return other.operator==(
entity);
196 template<
typename Entity>
198 return !(other ==
entity);
constexpr bool operator==(null_t) const noexcept
Compares two null objects.
std::uint32_t version_type
Underlying version type.
std::uint64_t entity_type
Underlying entity type.
constexpr auto to_integral(const Entity entity) noexcept
Converts an entity type to its underlying type.
std::uint32_t entity_type
Underlying entity type.
Null object for all entity identifiers.
constexpr bool operator==(const Entity entity) const noexcept
Compares a null object and an entity identifier of any type.
std::int64_t difference_type
Difference type.
std::uint8_t version_type
Underlying version type.
std::uint16_t entity_type
Underlying entity type.
std::int32_t difference_type
Difference type.
constexpr bool operator!=(null_t) const noexcept
Compares two null objects.
std::uint16_t version_type
Underlying version type.
std::int16_t difference_type
Difference type.
constexpr bool operator!=(const basic_hashed_string< Char > &lhs, const basic_hashed_string< Char > &rhs) noexcept
Compares two hashed strings.
constexpr bool operator==(const Entity entity, null_t other) noexcept
Compares a null object and an entity identifier of any type.
entity
Default entity identifier.
constexpr bool operator!=(const Entity entity) const noexcept
Compares a null object and an entity identifier of any type.