#include <type_traits>
#include <utility>
#include "irrlichttypes.h"
#include "IReferenceCounted.h"
Go to the source code of this file.
|
template<class ReferenceCounted > |
irr_ptr< ReferenceCounted > | grab (ReferenceCounted *object) noexcept |
| Constructs a shared pointer as a secondary reference to an object.
|
|
template<typename ReferenceCounted > |
bool | operator== (const irr_ptr< ReferenceCounted > &a, const irr_ptr< ReferenceCounted > &b) noexcept |
|
template<typename ReferenceCounted > |
bool | operator== (const irr_ptr< ReferenceCounted > &a, const ReferenceCounted *b) noexcept |
|
template<typename ReferenceCounted > |
bool | operator== (const ReferenceCounted *a, const irr_ptr< ReferenceCounted > &b) noexcept |
|
template<typename ReferenceCounted > |
bool | operator!= (const irr_ptr< ReferenceCounted > &a, const irr_ptr< ReferenceCounted > &b) noexcept |
|
template<typename ReferenceCounted > |
bool | operator!= (const irr_ptr< ReferenceCounted > &a, const ReferenceCounted *b) noexcept |
|
template<typename ReferenceCounted > |
bool | operator!= (const ReferenceCounted *a, const irr_ptr< ReferenceCounted > &b) noexcept |
|
template<class T , class... Args> |
irr_ptr< T > | make_irr (Args &&... args) |
| Same as std::make_unique<T>, but for irr_ptr.
|
|
◆ grab()
template<class ReferenceCounted >
irr_ptr< ReferenceCounted > grab |
( |
ReferenceCounted * | object | ) |
|
|
noexcept |
Constructs a shared pointer as a secondary reference to an object.
This function is intended to make a temporary reference to an object which is owned elsewhere so that it is not destroyed too early. To achieve that it does balanced reference counting, i.e. reference count is increased in this function and decreased when the returned pointer is destroyed.
References irr_ptr< ReferenceCounted, class >::grab().
Referenced by pauseNodeAnimation(), and GUIButtonImage::setFromStyle().
◆ make_irr()
template<class T , class... Args>
irr_ptr< T > make_irr |
( |
Args &&... | args | ) |
|
◆ operator!=() [1/3]
template<typename ReferenceCounted >
bool operator!= |
( |
const irr_ptr< ReferenceCounted > & | a, |
|
|
const irr_ptr< ReferenceCounted > & | b ) |
|
noexcept |
◆ operator!=() [2/3]
template<typename ReferenceCounted >
bool operator!= |
( |
const irr_ptr< ReferenceCounted > & | a, |
|
|
const ReferenceCounted * | b ) |
|
noexcept |
◆ operator!=() [3/3]
template<typename ReferenceCounted >
bool operator!= |
( |
const ReferenceCounted * | a, |
|
|
const irr_ptr< ReferenceCounted > & | b ) |
|
noexcept |
◆ operator==() [1/3]
template<typename ReferenceCounted >
bool operator== |
( |
const irr_ptr< ReferenceCounted > & | a, |
|
|
const irr_ptr< ReferenceCounted > & | b ) |
|
noexcept |
◆ operator==() [2/3]
template<typename ReferenceCounted >
bool operator== |
( |
const irr_ptr< ReferenceCounted > & | a, |
|
|
const ReferenceCounted * | b ) |
|
noexcept |
◆ operator==() [3/3]
template<typename ReferenceCounted >
bool operator== |
( |
const ReferenceCounted * | a, |
|
|
const irr_ptr< ReferenceCounted > & | b ) |
|
noexcept |