|
template<class to_t , class from_t > |
requires std::derived_from< from_t, rtti_pure_base > &&std::derived_from< to_t, rtti_pure_base > to_t * | qx::rtti_cast (from_t *pointer) |
| Returns to_t* if from_t is inherited from Y, otherwise nullptr. More...
|
|
template<class to_t , class from_t > |
requires std::derived_from< from_t, rtti_pure_base > &&std::derived_from< to_t, rtti_pure_base > to_t * | qx::rtti_cast (const std::shared_ptr< from_t > &pValue) |
| Returns to_t* if from_t is inherited from Y, otherwise nullptr. More...
|
|
template<class to_t , class from_t > |
requires std::derived_from< from_t, rtti_pure_base > &&std::derived_from< to_t, rtti_pure_base > to_t * | qx::rtti_cast (const std::unique_ptr< from_t > &pValue) |
| Returns to_t* if from_t is inherited from Y, otherwise nullptr. More...
|
|
template<class to_t , class from_t > |
requires std::derived_from< from_t, rtti_pure_base > &&std::derived_from< to_t, rtti_pure_base > to_t * | qx::rtti_cast (const link< from_t > &pValueLink) |
| Returns to_t* if from_t is inherited from Y, otherwise nullptr. More...
|
|
template<class to_t , class from_t > |
requires std::derived_from< from_t, rtti_pure_base > &&std::derived_from< to_t, rtti_pure_base > to_t * | qx::rtti_cast (from_t &value) |
| Returns to_t* if from_t is inherited from Y, otherwise nullptr. More...
|
|
- Author
- Khrapov
- Date
- 9.09.2021
- Copyright
- © Nick Khrapov, 2021. All right reserved.
Definition in file rtti_cast.h.
template<class to_t , class from_t >
requires std::derived_from<from_t, rtti_pure_base>&& std::derived_from<to_t, rtti_pure_base> to_t* qx::rtti_cast |
( |
from_t & |
value | ) |
|
Returns to_t* if from_t is inherited from Y, otherwise nullptr.
Pointer class should contain QX_RTTI_CLASS
- Template Parameters
-
to_t | - type to cast to |
from_t | - type to cast from |
- Parameters
-
- Return values
-
- | to_t* if from_t is inherited from Y, otherwise nullptr |
Definition at line 98 of file rtti_cast.h.