xentara-utils v2.0.4
The Xentara Utility Library
|
An object allocated indirectly on the heap. More...
#include <xentara/utils/memory/IndirectObject.hpp>
Public Member Functions | |
template<typename... Arguments> requires std::is_constructible_v<Object, Arguments &&...> && tools::kNotCopyMove<IndirectObject<Object>, Arguments...> | |
IndirectObject (Arguments &&... arguments) noexcept(std::is_nothrow_constructible_v< Object, Arguments &&... >) | |
In-place constructor. | |
IndirectObject (const IndirectObject &other) noexcept(std::is_nothrow_copy_constructible_v< Object >) | |
Copy constructor. | |
IndirectObject (IndirectObject &&other) noexcept | |
Move constructor. | |
auto | operator= (const IndirectObject &rhs) noexcept(std::is_nothrow_copy_assignable_v< IndirectObject > &&std::is_nothrow_copy_constructible_v< IndirectObject >) -> IndirectObject & |
Assignment operator. | |
auto | operator= (IndirectObject &&rhs) noexcept -> IndirectObject & |
Move assignment operator. | |
auto | operator* () const -> const Object & |
Gets the object. | |
auto | operator* () -> Object & |
Gets the object. | |
auto | operator-> () const -> const Object * |
Accesses a member of the object. | |
auto | operator-> () -> Object * |
Accesses a member of the object. | |
auto | operator== (const IndirectObject &rhs) noexcept -> bool |
Comparison operator. | |
auto | operator<=> (const IndirectObject &rhs) noexcept -> std::compare_three_way_result< Object, Object > |
Three-way comparison operator. | |
template<std::equality_comparable_with< Object > Other> requires (!std::same_as<Other, IndirectObject>) | |
auto | operator== (const Other &rhs) noexcept -> bool |
Comparison operator with another type. | |
template<std::three_way_comparable_with< Object > Other> requires (!std::same_as<Other, IndirectObject>) | |
auto | operator<=> (const IndirectObject &rhs) noexcept -> std::compare_three_way_result< Object, Other > |
Three-way comparison operator with another type. | |
template<typename... Arguments> requires std::is_constructible_v<Object, Arguments &&...> | |
auto | emplace (Arguments &&... arguments) noexcept(std::is_nothrow_constructible_v< Object, Arguments &&... >) -> void |
creates a new object with the given arguments | |
An object allocated indirectly on the heap.
|
noexcept |
In-place constructor.
Constructs an object with the given arguments
|
noexcept |
Copy constructor.
Copies the object.
|
noexcept |
Move constructor.
Transfers the object and leaves the source unusable.
|
noexcept |
creates a new object with the given arguments
auto xentara::utils::memory::IndirectObject< Object >::operator* | ( | ) | -> Object & |
Gets the object.
auto xentara::utils::memory::IndirectObject< Object >::operator* | ( | ) | const -> const Object & |
Gets the object.
auto xentara::utils::memory::IndirectObject< Object >::operator-> | ( | ) | -> Object * |
Accesses a member of the object.
auto xentara::utils::memory::IndirectObject< Object >::operator-> | ( | ) | const -> const Object * |
Accesses a member of the object.
|
noexcept |
Three-way comparison operator.
This operator compares the objects. Objects that have been moved away using the move constructor or move assignment operator only compare equal to themselves, and compare less than valid objects. When comparing two invalid objects, an arbitrary but consistent ordering will be returned.
|
noexcept |
Three-way comparison operator with another type.
This operator compares the object with another object. Objects that have been moved away using the move constructor or move assignment operator always compare less.
|
noexcept |
Assignment operator.
Assigns the object. If the object has been moved away using the move constructor or move assignment operator, a new copy is created.
|
noexcept |
Move assignment operator.
Transfers the object and leaves the source unusable. Any old object is destroyed.
|
noexcept |
Comparison operator.
This operator compares the objects. Objects that have been moved away using the move constructor or move assignment operator only compare equal to themselves.
|
noexcept |
Comparison operator with another type.
This operator compares the object with another object. Objects that have been moved away using the move constructor or move assignment operator always compare unequal.