PMEMKV  1.5.0-git3.g5c9f963
This is the C++ documentation for PMEMKV.
Classes | Namespaces | Macros | Typedefs | Enumerations | Functions
libpmemkv.hpp File Reference

Main C++ pmemkv public header. More...

#include <cassert>
#include <functional>
#include <iostream>
#include <libpmemobj++/slice.hpp>
#include <libpmemobj++/string_view.hpp>
#include <memory>
#include <stdexcept>
#include <string>
#include <utility>
#include "libpmemkv.h"
#include <libpmemobj/pool_base.h>

Go to the source code of this file.

Classes

class  pmem::kv::bad_result_access
 Defines a type of object to be thrown by result::get_value() when result doesn't contain value. More...
 
class  pmem::kv::result< T >
 Stores result of an operation. It always contains status and optionally can contain value. More...
 
class  pmem::kv::config
 Holds configuration parameters for engines. More...
 
class  pmem::kv::tx
 Pmemkv transaction handle. More...
 
class  pmem::kv::db
 Main pmemkv class, it provides functions to operate on data in database. More...
 
class  pmem::kv::db::iterator< IsConst >
 Iterator provides methods to iterate over records in db. More...
 
class  pmem::kv::db::iterator< IsConst >::OutputIterator< T >
 OutputIterator provides iteration through elements without a possibility of reading them. It is only allowed to modify them. More...
 
struct  pmem::kv::db::iterator< IsConst >::OutputIterator< T >::assign_only
 
struct  pmem::kv::internal::unique_ptr_wrapper_base
 
struct  pmem::kv::internal::unique_ptr_wrapper< T, D >
 
class  pmem::kv::internal::comparator_base
 
struct  pmem::kv::internal::comparator_wrapper< Comparator >
 
struct  pmem::kv::internal::comparator_config_entry
 

Namespaces

 pmem
 Persistent memory namespace.
 
 pmem::kv
 Main pmemkv namespace.
 
 pmem::kv::internal
 Internal pmemkv classes for C++ API.
 

Macros

#define force_create_deprecated    __attribute__((deprecated("use config::put_create_or_error_if_exists instead")))
 

Typedefs

using pmem::kv::string_view = obj::string_view
 Partial string_view implementation, defined in pmem::obj namespace in libpmemobj-cpp library (see: https://pmem.io/libpmemobj-cpp ). More...
 
typedef int pmem::kv::get_kv_function(string_view key, string_view value)
 The C++ idiomatic function type to use for callback using key-value pair. More...
 
typedef void pmem::kv::get_v_function(string_view value)
 The C++ idiomatic function type to use for callback using only the value. More...
 
using pmem::kv::get_kv_callback = pmemkv_get_kv_callback
 Key-value pair callback, C-style. More...
 
using pmem::kv::get_v_callback = pmemkv_get_v_callback
 Value-only callback, C-style. More...
 

Enumerations

enum class  pmem::kv::status {
  pmem::kv::OK = PMEMKV_STATUS_OK , pmem::kv::UNKNOWN_ERROR = PMEMKV_STATUS_UNKNOWN_ERROR , pmem::kv::NOT_FOUND = PMEMKV_STATUS_NOT_FOUND , pmem::kv::NOT_SUPPORTED = PMEMKV_STATUS_NOT_SUPPORTED ,
  pmem::kv::INVALID_ARGUMENT = PMEMKV_STATUS_INVALID_ARGUMENT , pmem::kv::CONFIG_PARSING_ERROR , pmem::kv::CONFIG_TYPE_ERROR , pmem::kv::STOPPED_BY_CB = PMEMKV_STATUS_STOPPED_BY_CB ,
  pmem::kv::OUT_OF_MEMORY , pmem::kv::WRONG_ENGINE_NAME , pmem::kv::TRANSACTION_SCOPE_ERROR , pmem::kv::DEFRAG_ERROR = PMEMKV_STATUS_DEFRAG_ERROR ,
  pmem::kv::COMPARATOR_MISMATCH
}
 Status returned by most of pmemkv functions. More...
 

Functions

std::ostream & pmem::kv::operator<< (std::ostream &os, const status &s)
 Provides string representation of a status, along with its number as specified by enum. More...
 
template<typename T >
bool pmem::kv::operator== (const result< T > &lhs, const status &rhs)
 
template<typename T >
bool pmem::kv::operator== (const status &lhs, const result< T > &rhs)
 
template<typename T >
bool pmem::kv::operator!= (const result< T > &lhs, const status &rhs)
 
template<typename T >
bool pmem::kv::operator!= (const status &lhs, const result< T > &rhs)
 

Detailed Description

Main C++ pmemkv public header.

It contains all pmemkv public types, enums, classes with their functions and members.

Macro Definition Documentation

◆ force_create_deprecated

#define force_create_deprecated    __attribute__((deprecated("use config::put_create_or_error_if_exists instead")))