PMDK C++ bindings
1.8.1
This is the C++ bindings documentation for PMDK's libpmemobj.
|
Persistent smart pointer. More...
#include <cassert>
#include <limits>
#include <memory>
#include <ostream>
#include <libpmemobj++/detail/common.hpp>
#include <libpmemobj++/detail/persistent_ptr_base.hpp>
#include <libpmemobj++/detail/specialization.hpp>
#include <libpmemobj++/pool.hpp>
#include <libpmemobj/base.h>
Go to the source code of this file.
Classes | |
class | pmem::obj::persistent_ptr< T > |
Persistent pointer class. More... | |
Namespaces | |
pmem | |
A persistent version of concurrent hash map implementation Ref: https://arxiv.org/abs/1509.02235. | |
Functions | |
template<class T > | |
void | pmem::obj::swap (persistent_ptr< T > &a, persistent_ptr< T > &b) |
Swaps two persistent_ptr objects of the same type. More... | |
template<typename T , typename Y > | |
bool | pmem::obj::operator== (persistent_ptr< T > const &lhs, persistent_ptr< Y > const &rhs) noexcept |
Equality operator. More... | |
template<typename T , typename Y > | |
bool | pmem::obj::operator!= (persistent_ptr< T > const &lhs, persistent_ptr< Y > const &rhs) noexcept |
Inequality operator. | |
template<typename T > | |
bool | pmem::obj::operator== (persistent_ptr< T > const &lhs, std::nullptr_t) noexcept |
Equality operator with nullptr. | |
template<typename T > | |
bool | pmem::obj::operator== (std::nullptr_t, persistent_ptr< T > const &lhs) noexcept |
Equality operator with nullptr. | |
template<typename T > | |
bool | pmem::obj::operator!= (persistent_ptr< T > const &lhs, std::nullptr_t) noexcept |
Inequality operator with nullptr. | |
template<typename T > | |
bool | pmem::obj::operator!= (std::nullptr_t, persistent_ptr< T > const &lhs) noexcept |
Inequality operator with nullptr. | |
template<typename T , typename Y > | |
bool | pmem::obj::operator< (persistent_ptr< T > const &lhs, persistent_ptr< Y > const &rhs) noexcept |
Less than operator. More... | |
template<typename T , typename Y > | |
bool | pmem::obj::operator<= (persistent_ptr< T > const &lhs, persistent_ptr< Y > const &rhs) noexcept |
Less or equal than operator. More... | |
template<typename T , typename Y > | |
bool | pmem::obj::operator> (persistent_ptr< T > const &lhs, persistent_ptr< Y > const &rhs) noexcept |
Greater than operator. More... | |
template<typename T , typename Y > | |
bool | pmem::obj::operator>= (persistent_ptr< T > const &lhs, persistent_ptr< Y > const &rhs) noexcept |
Greater or equal than operator. More... | |
template<typename T > | |
bool | pmem::obj::operator< (persistent_ptr< T > const &lhs, std::nullptr_t) noexcept |
Compare a persistent_ptr with a null pointer. | |
template<typename T > | |
bool | pmem::obj::operator< (std::nullptr_t, persistent_ptr< T > const &rhs) noexcept |
Compare a persistent_ptr with a null pointer. | |
template<typename T > | |
bool | pmem::obj::operator<= (persistent_ptr< T > const &lhs, std::nullptr_t) noexcept |
Compare a persistent_ptr with a null pointer. | |
template<typename T > | |
bool | pmem::obj::operator<= (std::nullptr_t, persistent_ptr< T > const &rhs) noexcept |
Compare a persistent_ptr with a null pointer. | |
template<typename T > | |
bool | pmem::obj::operator> (persistent_ptr< T > const &lhs, std::nullptr_t) noexcept |
Compare a persistent_ptr with a null pointer. | |
template<typename T > | |
bool | pmem::obj::operator> (std::nullptr_t, persistent_ptr< T > const &rhs) noexcept |
Compare a persistent_ptr with a null pointer. | |
template<typename T > | |
bool | pmem::obj::operator>= (persistent_ptr< T > const &lhs, std::nullptr_t) noexcept |
Compare a persistent_ptr with a null pointer. | |
template<typename T > | |
bool | pmem::obj::operator>= (std::nullptr_t, persistent_ptr< T > const &rhs) noexcept |
Compare a persistent_ptr with a null pointer. | |
template<typename T > | |
persistent_ptr< T > | pmem::obj::operator+ (persistent_ptr< T > const &lhs, std::ptrdiff_t s) |
Addition operator for persistent pointers. | |
template<typename T > | |
persistent_ptr< T > | pmem::obj::operator- (persistent_ptr< T > const &lhs, std::ptrdiff_t s) |
Subtraction operator for persistent pointers. | |
template<typename T , typename Y , typename = typename std::enable_if< std::is_same<typename std::remove_cv<T>::type, typename std::remove_cv<Y>::type>::value>> | |
ptrdiff_t | pmem::obj::operator- (persistent_ptr< T > const &lhs, persistent_ptr< Y > const &rhs) |
Subtraction operator for persistent pointers of identical type. More... | |
template<typename T > | |
std::ostream & | pmem::obj::operator<< (std::ostream &os, persistent_ptr< T > const &pptr) |
Ostream operator for the persistent pointer. | |
Persistent smart pointer.
|
inline |
Subtraction operator for persistent pointers of identical type.
Calculates the offset difference of PMEMoids in terms of represented objects. Calculating the difference of pointers from objects of different pools is not allowed.
|
inlinenoexcept |
Less than operator.
|
inlinenoexcept |
Less or equal than operator.
See less than operator for comparison rules.
|
inlinenoexcept |
Equality operator.
This checks if underlying PMEMoids are equal.
|
inlinenoexcept |
Greater than operator.
See less than operator for comparison rules.
|
inlinenoexcept |
Greater or equal than operator.
See less than operator for comparison rules.
|
inline |
Swaps two persistent_ptr objects of the same type.
Non-member swap function as required by Swappable concept. en.cppreference.com/w/cpp/concept/Swappable