9 #ifndef LIBPMEMOBJ_CPP_P_HPP 10 #define LIBPMEMOBJ_CPP_P_HPP 46 p(
const T &_val) noexcept : val{_val}
68 this_type(rhs).
swap(*
this);
84 typename =
typename std::enable_if<
85 std::is_convertible<Y, T>::value>::type>
89 this_type(rhs).
swap(*
this);
97 operator T() const noexcept
115 detail::conditional_add_to_tx(
this);
142 detail::conditional_add_to_tx(
this);
143 detail::conditional_add_to_tx(&other);
Helper template for persistent ptr specialization.
T & get_rw()
Retrieves read-write reference of the object.
Definition: p.hpp:113
Commonly used functionality.
p(const T &_val) noexcept
Value constructor.
Definition: p.hpp:46
p & operator=(const p &rhs)
Assignment operator.
Definition: p.hpp:66
const T & get_ro() const noexcept
Retrieves read-only const reference of the object.
Definition: p.hpp:128
void swap(p &other)
Swaps two p objects of the same type.
Definition: p.hpp:140
void swap(p< T > &a, p< T > &b)
Swaps two p objects of the same type.
Definition: p.hpp:159
Resides on pmem class.
Definition: p.hpp:35
Persistent memory namespace.
Definition: allocation_flag.hpp:14
p()=default
Defaulted constructor.
p & operator=(const p< Y > &rhs)
Converting assignment operator from a different p<>.
Definition: p.hpp:87