9#ifndef LIBPMEMOBJ_CPP_PERSISTENT_PTR_BASE_HPP
10#define LIBPMEMOBJ_CPP_PERSISTENT_PTR_BASE_HPP
17#include <libpmemobj/base.h>
20#if defined(max) && defined(_WIN32)
81 : oid(std::move(r.oid))
91 detail::conditional_add_to_tx(
this);
92 this->oid = std::move(r.oid);
110 detail::conditional_add_to_tx(
this);
125 detail::conditional_add_to_tx(
this);
138 detail::conditional_add_to_tx(
this);
139 detail::conditional_add_to_tx(&other);
140 std::swap(this->oid, other.oid);
Persistent_ptr base (non-template) class.
Definition: persistent_ptr_base.hpp:42
persistent_ptr_base & operator=(persistent_ptr_base &&r)
Move assignment operator.
Definition: persistent_ptr_base.hpp:89
const PMEMoid & raw() const noexcept
Get PMEMoid encapsulated by this object.
Definition: persistent_ptr_base.hpp:151
void swap(persistent_ptr_base &other)
Swaps two persistent_ptr objects of the same type.
Definition: persistent_ptr_base.hpp:136
PMEMoid * raw_ptr() noexcept
Get pointer to PMEMoid encapsulated by this object.
Definition: persistent_ptr_base.hpp:164
persistent_ptr_base() noexcept
Default constructor, zeroes the PMEMoid.
Definition: persistent_ptr_base.hpp:47
persistent_ptr_base(PMEMoid oid) noexcept
PMEMoid constructor.
Definition: persistent_ptr_base.hpp:64
persistent_ptr_base & operator=(persistent_ptr_base const &r)
Assignment operator.
Definition: persistent_ptr_base.hpp:108
persistent_ptr_base(persistent_ptr_base &&r) noexcept
Move constructor.
Definition: persistent_ptr_base.hpp:80
persistent_ptr_base & operator=(std::nullptr_t &&)
Nullptr move assignment operator.
Definition: persistent_ptr_base.hpp:123
Commonly used functionality.
Persistent memory namespace.
Definition: allocation_flag.hpp:15
Helper template for persistent ptr specialization.