23 std::is_convertible_v<
44 std::is_convertible_v<
65 std::is_convertible_v<
80 if (
this != std::addressof(a_rhs)) {
92 std::is_convertible_v<
107 if (
this != std::addressof(a_rhs)) {
110 a_rhs._ptr =
nullptr;
119 std::is_convertible_v<
127 a_rhs._ptr =
nullptr;
136 std::is_convertible_v<
154 [[nodiscard]]
explicit constexpr operator bool() const noexcept
156 return static_cast<bool>(
_ptr);
161 assert(
static_cast<bool>(*
this));
167 assert(
static_cast<bool>(*
this));
195 template <
class T,
class... Args>
198 return NiPointer<T>{
new T(std::forward<Args>(a_args)...) };
201 template <
class T1,
class T2>
204 return a_lhs.
get() == a_rhs.
get();
207 template <
class T1,
class T2>
210 return !(a_lhs == a_rhs);
228 return static_cast<bool>(a_lhs);
234 return static_cast<bool>(a_rhs);
251#define NiSmartPointer(className) \
253 using className##Ptr = RE::NiPointer<className>
Definition NiSmartPointer.h:9
void reset()
Definition NiSmartPointer.h:131
NiPointer(NiPointer &&a_rhs) noexcept
Definition NiSmartPointer.h:55
constexpr element_type & operator*() const noexcept
Definition NiSmartPointer.h:159
NiPointer & operator=(const NiPointer< Y > &a_rhs)
Definition NiSmartPointer.h:96
NiPointer & operator=(NiPointer< Y > &&a_rhs)
Definition NiSmartPointer.h:123
NiPointer & operator=(const NiPointer &a_rhs)
Definition NiSmartPointer.h:78
void TryDetach()
Definition NiSmartPointer.h:182
constexpr element_type * operator->() const noexcept
Definition NiSmartPointer.h:165
T element_type
Definition NiSmartPointer.h:11
~NiPointer()
Definition NiSmartPointer.h:75
NiPointer(Y *a_rhs)
Definition NiSmartPointer.h:27
NiPointer(const NiPointer< Y > &a_rhs)
Definition NiSmartPointer.h:48
NiPointer(const NiPointer &a_rhs)
Definition NiSmartPointer.h:34
constexpr element_type * get() const noexcept
Definition NiSmartPointer.h:149
NiPointer & operator=(NiPointer &&a_rhs)
Definition NiSmartPointer.h:105
void TryAttach()
Definition NiSmartPointer.h:175
constexpr NiPointer() noexcept=default
NiPointer(NiPointer< Y > &&a_rhs) noexcept
Definition NiSmartPointer.h:69
void reset(Y *a_ptr)
Definition NiSmartPointer.h:140
element_type * _ptr
Definition NiSmartPointer.h:191
Definition AbsorbEffect.h:6
NiPointer< T > make_nismart(Args &&... a_args)
Definition NiSmartPointer.h:196
constexpr bool operator==(const BSTSmartPointer< T1 > &a_lhs, const BSTSmartPointer< T2 > &a_rhs)
Definition BSTSmartPointer.h:240
constexpr bool operator!=(const BSTSmartPointer< T1 > &a_lhs, const BSTSmartPointer< T2 > &a_rhs)
Definition BSTSmartPointer.h:246
Definition ActorValueList.h:28
std::uint32_t operator()(const NiPointer< T > &a_key) const noexcept
Definition NiSmartPointer.h:244