|
tenno 0.1.0
|
A shared pointer. More...
#include <memory.hpp>
Public Types | |
| using | pointer = T * |
| using | element_type = T |
| using | deleter_type = Deleter |
Public Member Functions | |
| constexpr | unique_ptr () |
| Construct a new empty unique_ptr object. | |
| constexpr | unique_ptr (T *ptr, Deleter deleter=tenno::default_delete< T >()) |
| Construct a new unique_ptr object with the given pointer. | |
| constexpr | unique_ptr (const unique_ptr &other)=delete |
| constexpr | unique_ptr (unique_ptr &&other) noexcept |
| Construct a new unique_ptr object by moving the other object. | |
| ~unique_ptr () | |
| Destroy the unique_ptr object. | |
| constexpr unique_ptr & | operator= (const unique_ptr &other)=delete |
| constexpr unique_ptr & | operator= (unique_ptr &&other) noexcept |
| Move the other unique_ptr object into this one. | |
| constexpr pointer | release () noexcept |
| Release the pointer from the unique_ptr object. | |
| constexpr void | reset (pointer ptr=pointer()) noexcept |
| Reset the pointer to the given value. | |
| void | swap (unique_ptr &other) noexcept |
| Swap the unique_ptr object with the other one. | |
| constexpr pointer | get () const noexcept |
| Get the pointer to the object. | |
| deleter_type & | get_deleter () |
| Get the deleter of the object. | |
| operator bool () const noexcept | |
| Boolean conversion operator. | |
| T & | operator* () noexcept |
| Dereference operator. | |
| T & | operator-> () noexcept |
| Dereference operator. | |
A shared pointer.
| T | The type of the object to point to |
Definition at line 846 of file memory.hpp.
| using tenno::unique_ptr< T, Deleter >::deleter_type = Deleter |
Definition at line 851 of file memory.hpp.
| using tenno::unique_ptr< T, Deleter >::element_type = T |
Definition at line 850 of file memory.hpp.
| using tenno::unique_ptr< T, Deleter >::pointer = T * |
Definition at line 849 of file memory.hpp.
|
inlineconstexpr |
Construct a new empty unique_ptr object.
Definition at line 856 of file memory.hpp.
|
inlineconstexpr |
Construct a new unique_ptr object with the given pointer.
| ptr | The pointer to the object |
Definition at line 865 of file memory.hpp.
|
constexprdelete |
|
inlineconstexprnoexcept |
Construct a new unique_ptr object by moving the other object.
| other | The other unique_ptr object to move |
Definition at line 876 of file memory.hpp.
|
inline |
Destroy the unique_ptr object.
Definition at line 888 of file memory.hpp.
|
inlineconstexprnoexcept |
Get the pointer to the object.
Definition at line 955 of file memory.hpp.
|
inline |
Get the deleter of the object.
Definition at line 965 of file memory.hpp.
|
inlineexplicitnoexcept |
Boolean conversion operator.
Definition at line 974 of file memory.hpp.
|
inlinenoexcept |
Dereference operator.
Definition at line 983 of file memory.hpp.
|
inlinenoexcept |
Dereference operator.
Definition at line 992 of file memory.hpp.
|
constexprdelete |
|
inlineconstexprnoexcept |
Move the other unique_ptr object into this one.
| other | The other unique_ptr object to move |
Definition at line 901 of file memory.hpp.
|
inlineconstexprnoexcept |
Release the pointer from the unique_ptr object.
Definition at line 913 of file memory.hpp.
|
inlineconstexprnoexcept |
Reset the pointer to the given value.
| ptr | The pointer to the object |
Definition at line 928 of file memory.hpp.
|
inlinenoexcept |
Swap the unique_ptr object with the other one.
| other | The other unique_ptr object to swap with |
Definition at line 940 of file memory.hpp.