OpenLexocad
28.0
|
Opaque container for meta types. More...
#include <entt.hpp>
Public Types | |
using | size_type = typename internal::meta_type_node::size_type |
Unsigned integer type. More... | |
Public Member Functions | |
meta_type (const internal::meta_type_node *curr=nullptr) ENTT_NOEXCEPT | |
Constructs an instance from a given node. More... | |
ENTT_ID_TYPE | identifier () const ENTT_NOEXCEPT |
Returns the identifier assigned to a given meta object. More... | |
bool | is_void () const ENTT_NOEXCEPT |
Indicates whether a given meta type refers to void or not. More... | |
bool | is_integral () const ENTT_NOEXCEPT |
Indicates whether a given meta type refers to an integral type or not. More... | |
bool | is_floating_point () const ENTT_NOEXCEPT |
Indicates whether a given meta type refers to a floating-point type or not. More... | |
bool | is_array () const ENTT_NOEXCEPT |
Indicates whether a given meta type refers to an array type or not. More... | |
bool | is_enum () const ENTT_NOEXCEPT |
Indicates whether a given meta type refers to an enum or not. More... | |
bool | is_union () const ENTT_NOEXCEPT |
Indicates whether a given meta type refers to an union or not. More... | |
bool | is_class () const ENTT_NOEXCEPT |
Indicates whether a given meta type refers to a class or not. More... | |
bool | is_pointer () const ENTT_NOEXCEPT |
Indicates whether a given meta type refers to a pointer or not. More... | |
bool | is_function_pointer () const ENTT_NOEXCEPT |
Indicates whether a given meta type refers to a function pointer or not. More... | |
bool | is_member_object_pointer () const ENTT_NOEXCEPT |
Indicates whether a given meta type refers to a pointer to data member or not. More... | |
bool | is_member_function_pointer () const ENTT_NOEXCEPT |
Indicates whether a given meta type refers to a pointer to member function or not. More... | |
size_type | extent () const ENTT_NOEXCEPT |
If a given meta type refers to an array type, provides the number of elements of the array. More... | |
meta_type | remove_pointer () const ENTT_NOEXCEPT |
Provides the meta type for which the pointer is defined. More... | |
meta_type | remove_extent () const ENTT_NOEXCEPT |
Provides the meta type for which the array is defined. More... | |
template<typename Op > | |
std::enable_if_t< std::is_invocable_v< Op, meta_base >, void > | base (Op op) const ENTT_NOEXCEPT |
Iterates all the meta base of a meta type. More... | |
meta_base | base (const ENTT_ID_TYPE identifier) const ENTT_NOEXCEPT |
Returns the meta base associated with a given identifier. More... | |
template<typename Op > | |
void | conv (Op op) const ENTT_NOEXCEPT |
Iterates all the meta conversion functions of a meta type. More... | |
template<typename Type > | |
meta_conv | conv () const ENTT_NOEXCEPT |
Returns the meta conversion function associated with a given type. More... | |
template<typename Op > | |
void | ctor (Op op) const ENTT_NOEXCEPT |
Iterates all the meta constructors of a meta type. More... | |
template<typename... Args> | |
meta_ctor | ctor () const ENTT_NOEXCEPT |
Returns the meta constructor that accepts a given list of types of arguments. More... | |
meta_dtor | dtor () const ENTT_NOEXCEPT |
Returns the meta destructor associated with a given type. More... | |
template<typename Op > | |
std::enable_if_t< std::is_invocable_v< Op, meta_data >, void > | data (Op op) const ENTT_NOEXCEPT |
Iterates all the meta data of a meta type. More... | |
meta_data | data (const ENTT_ID_TYPE identifier) const ENTT_NOEXCEPT |
Returns the meta data associated with a given identifier. More... | |
template<typename Op > | |
std::enable_if_t< std::is_invocable_v< Op, meta_func >, void > | func (Op op) const ENTT_NOEXCEPT |
Iterates all the meta functions of a meta type. More... | |
meta_func | func (const ENTT_ID_TYPE identifier) const ENTT_NOEXCEPT |
Returns the meta function associated with a given identifier. More... | |
template<typename... Args> | |
meta_any | construct (Args &&... args) const |
Creates an instance of the underlying type, if possible. More... | |
bool | destroy (meta_handle handle) const |
Destroys an instance of the underlying type. More... | |
template<typename Op > | |
std::enable_if_t< std::is_invocable_v< Op, meta_prop >, void > | prop (Op op) const ENTT_NOEXCEPT |
Iterates all the properties assigned to a meta type. More... | |
meta_prop | prop (meta_any key) const ENTT_NOEXCEPT |
Returns the property associated with a given key. More... | |
operator bool () const ENTT_NOEXCEPT | |
Returns true if a meta object is valid, false otherwise. More... | |
bool | operator== (const meta_type &other) const ENTT_NOEXCEPT |
Checks if two meta objects refer to the same node. More... | |
Opaque container for meta types.
using entt::meta_type::size_type = typename internal::meta_type_node::size_type |
Unsigned integer type.
|
inline |
Constructs an instance from a given node.
curr | The underlying node with which to construct the instance. |
|
inline |
Returns the meta base associated with a given identifier.
Searches recursively among all the base classes of the given type.
identifier | Unique identifier. |
|
inline |
Iterates all the meta base of a meta type.
Iteratively returns all the base classes of the given type.
Op | Type of the function object to invoke. |
op | A valid function object. |
|
inline |
Creates an instance of the underlying type, if possible.
To create a valid instance, the types of the parameters must coincide exactly with those required by the underlying meta constructor. Otherwise, an empty and then invalid container is returned.
Args | Types of arguments to use to construct the instance. |
args | Parameters to use to construct the instance. |
|
inline |
Returns the meta conversion function associated with a given type.
Searches recursively among all the conversion functions of the given type.
Type | The type to use to search for a meta conversion function. |
|
inline |
Iterates all the meta conversion functions of a meta type.
Iteratively returns all the meta conversion functions of the given type.
Op | Type of the function object to invoke. |
op | A valid function object. |
|
inline |
Returns the meta constructor that accepts a given list of types of arguments.
|
inline |
Iterates all the meta constructors of a meta type.
Op | Type of the function object to invoke. |
op | A valid function object. |
|
inline |
Returns the meta data associated with a given identifier.
Searches recursively among all the meta data of the given type. This means that the meta data of the base classes will also be inspected, if any.
identifier | Unique identifier. |
|
inline |
Iterates all the meta data of a meta type.
Iteratively returns all the meta data of the given type. This means that the meta data of the base classes will also be returned, if any.
Op | Type of the function object to invoke. |
op | A valid function object. |
|
inline |
Destroys an instance of the underlying type.
It must be possible to cast the instance to the underlying type. Otherwise, invoking the meta destructor results in an undefined behavior.
If no destructor has been set, this function returns true without doing anything.
handle | An opaque pointer to an instance of the underlying type. |
|
inline |
Returns the meta destructor associated with a given type.
|
inline |
If a given meta type refers to an array type, provides the number of elements of the array.
|
inline |
Returns the meta function associated with a given identifier.
Searches recursively among all the meta functions of the given type. This means that the meta functions of the base classes will also be inspected, if any.
identifier | Unique identifier. |
|
inline |
Iterates all the meta functions of a meta type.
Iteratively returns all the meta functions of the given type. This means that the meta functions of the base classes will also be returned, if any.
Op | Type of the function object to invoke. |
op | A valid function object. |
|
inline |
Returns the identifier assigned to a given meta object.
|
inline |
Indicates whether a given meta type refers to an array type or not.
|
inline |
Indicates whether a given meta type refers to a class or not.
|
inline |
Indicates whether a given meta type refers to an enum or not.
|
inline |
Indicates whether a given meta type refers to a floating-point type or not.
|
inline |
Indicates whether a given meta type refers to a function pointer or not.
|
inline |
Indicates whether a given meta type refers to an integral type or not.
|
inline |
Indicates whether a given meta type refers to a pointer to member function or not.
|
inline |
Indicates whether a given meta type refers to a pointer to data member or not.
|
inline |
Indicates whether a given meta type refers to a pointer or not.
|
inline |
Indicates whether a given meta type refers to an union or not.
|
inline |
Indicates whether a given meta type refers to void or not.
|
inlineexplicit |
Returns true if a meta object is valid, false otherwise.
|
inline |
Checks if two meta objects refer to the same node.
other | The meta object with which to compare. |
Returns the property associated with a given key.
Searches recursively among all the properties of the given type. This means that the properties of the base classes will also be inspected, if any.
key | The key to use to search for a property. |
|
inline |
Iterates all the properties assigned to a meta type.
Iteratively returns all the properties of the given type. This means that the properties of the base classes will also be returned, if any.
Op | Type of the function object to invoke. |
op | A valid function object. |
|
inline |
Provides the meta type for which the array is defined.
|
inline |
Provides the meta type for which the pointer is defined.