memory.hpp
Go to the documentation of this file.
33 inline ememory::SharedPtr<EMEMORY_TYPE_CAST> dynamicPointerCast(ememory::SharedPtr<EMEMORY_TYPE>& _obj) {
34 return ememory::SharedPtr<EMEMORY_TYPE_CAST>(dynamic_cast<EMEMORY_TYPE_CAST*>(_obj.get()), _obj.getCounter());
42 inline const ememory::SharedPtr<EMEMORY_TYPE_CAST> dynamicPointerCast(const ememory::SharedPtr<EMEMORY_TYPE>& _obj) {
43 return ememory::SharedPtr<EMEMORY_TYPE_CAST>(dynamic_cast<EMEMORY_TYPE_CAST*>(const_cast<EMEMORY_TYPE*>(_obj.get())), _obj.getCounter());
51 inline ememory::SharedPtr<EMEMORY_TYPE_CAST> staticPointerCast(ememory::SharedPtr<EMEMORY_TYPE>& _obj) {
52 return ememory::SharedPtr<EMEMORY_TYPE_CAST>(static_cast<EMEMORY_TYPE_CAST*>(_obj.get()), _obj.getCounter());
60 inline const ememory::SharedPtr<EMEMORY_TYPE_CAST> staticPointerCast(const ememory::SharedPtr<EMEMORY_TYPE>& _obj) {
61 return ememory::SharedPtr<EMEMORY_TYPE_CAST>(static_cast<EMEMORY_TYPE_CAST*>(const_cast<EMEMORY_TYPE*>(_obj.get())), _obj.getCounter());
69 inline ememory::SharedPtr<EMEMORY_TYPE_CAST> reinterpretPointerCast(ememory::SharedPtr<EMEMORY_TYPE>& _obj) {
70 return ememory::SharedPtr<EMEMORY_TYPE_CAST>(reinterpret_cast<EMEMORY_TYPE_CAST*>(_obj.get()), _obj.getCounter());
78 inline const ememory::SharedPtr<EMEMORY_TYPE_CAST> reinterpretPointerCast(const ememory::SharedPtr<EMEMORY_TYPE>& _obj) {
79 return ememory::SharedPtr<EMEMORY_TYPE_CAST>(reinterpret_cast<EMEMORY_TYPE_CAST*>(const_cast<EMEMORY_TYPE*>(_obj.get())), _obj.getCounter());
87 inline ememory::SharedPtr<EMEMORY_TYPE_CAST> constPointerCast(const ememory::SharedPtr<EMEMORY_TYPE>& _obj) {
88 return ememory::SharedPtr<EMEMORY_TYPE_CAST>(const_cast<EMEMORY_TYPE*>(_obj.get()), _obj.getCounter());
ememory::SharedPtr< EMEMORY_TYPE_CAST > staticPointerCast(ememory::SharedPtr< EMEMORY_TYPE > &_obj)
Cast in static the input SharedPtr into an other type like static_cast on pointer.
Definition: memory.hpp:51
ememory::SharedPtr< EMEMORY_TYPE_CAST > dynamicPointerCast(ememory::SharedPtr< EMEMORY_TYPE > &_obj)
Cast in Dynamic the input SharedPtr into an other type like dynamic_cast on pointer.
Definition: memory.hpp:33
ememory::SharedPtr< EMEMORY_TYPE_CAST > reinterpretPointerCast(ememory::SharedPtr< EMEMORY_TYPE > &_obj)
Cast in reinterpret the input SharedPtr into an other type like reinterpret_cast on pointer...
Definition: memory.hpp:69
ememory::SharedPtr< EMEMORY_TYPE_CAST > constPointerCast(const ememory::SharedPtr< EMEMORY_TYPE > &_obj)
Cast in const the input SharedPtr into an other type like const_cast on pointer (remove constness) ...
Definition: memory.hpp:87