PMDK C++ bindings
1.6.1
This is the C++ bindings documentation for PMDK's libpmemobj.
|
pmem::obj::experimental::v - volatile resides on pmem class. More...
#include <libpmemobj++/experimental/v.hpp>
Public Member Functions | |
v () noexcept | |
Defaulted constructor. | |
~v () | |
Destructor. | |
v & | operator= (const T &rhs) |
Assignment operator. | |
v & | operator= (v &rhs) |
Assignment operator. | |
template<typename Y , typename = typename std::enable_if< std::is_convertible<Y, T>::value>::type> | |
v & | operator= (v< Y > &rhs) |
Converting assignment operator from a different v<>. More... | |
template<typename... Args> | |
T & | get (Args &&... args) noexcept |
Retrieves reference to the object. More... | |
T & | unsafe_get () |
Retrieves reference to the object. More... | |
operator T& () noexcept | |
Conversion operator back to the underlying type. | |
void | swap (v &other) |
Swaps two v objects of the same type. | |
pmem::obj::experimental::v - volatile resides on pmem class.
v class is a property-like template class that has to be used for all volatile variables that reside on persistent memory. This class ensures that the enclosed type is always properly initialized by always calling the class default constructor exactly once per instance of the application. This class has 8 bytes of storage overhead.
|
inlinenoexcept |
Retrieves reference to the object.
[in] | args | forwarded to objects constructor. If object was constructed earlier during application lifetime (even with different arguments) no constructor is called. |
|
inline |
Converting assignment operator from a different v<>.
Available only for convertible types.
|
inline |
Retrieves reference to the object.
If object was not constructed (e.g. using get()) return value is unspecified.