28 #ifndef RTTR_ENUMERATION_H_
29 #define RTTR_ENUMERATION_H_
31 #include "rttr/detail/base/core_prerequisites.h"
34 #include "rttr/detail/misc/class_item_mapper.h"
47 class enumeration_wrapper_base;
112 class RTTR_API enumeration
120 bool is_valid() const RTTR_NOEXCEPT;
127 explicit operator
bool() const RTTR_NOEXCEPT;
141 type get_underlying_type() const RTTR_NOEXCEPT;
148 type get_type() const RTTR_NOEXCEPT;
158 type get_declaring_type() const RTTR_NOEXCEPT;
168 variant get_metadata(const variant& key) const;
177 array_range<
string_view> get_names() const RTTR_NOEXCEPT;
187 array_range<variant> get_values() const RTTR_NOEXCEPT;
209 bool operator==(const enumeration& other) const RTTR_NOEXCEPT;
216 bool operator!=(const enumeration& other) const RTTR_NOEXCEPT;
219 enumeration(const detail::enumeration_wrapper_base* wrapper) RTTR_NOEXCEPT;
222 friend T detail::create_item(const detail::class_item_to_wrapper_t<T>* wrapper);
224 friend T detail::create_invalid_item();
226 const detail::enumeration_wrapper_base* m_wrapper;
231 #endif // RTTR_ENUMERATION_H_