Struct mdbx::pair
Combines pair of slices for key and value to represent result of certain operations.
#include <mdbx.h++>
Inherited by the following classes: mdbx::cursor::estimate_result, mdbx::pair_result
Public Types
| Type | Name |
|---|---|
| typedef std::pair< slice, slice > | stl_pair An alias for std::pair< slice , slice > . |
Public Attributes
| Type | Name |
|---|---|
| slice | key The key part of the pair. |
| slice | value The value part of the pair. |
Public Functions
| Type | Name |
|---|---|
| constexpr | operator stl_pair () noexcept const Converts the pair to a std::pair of slices. |
| pair & | operator= (const pair &) noexcept Copy assignment operator. |
| pair & | operator= (pair && couple) noexcept Move assignment operator. |
| pair & | operator= (const stl_pair & couple) Assigns the pair from a std::pair of slices. |
| pair & | operator= (stl_pair && couple) Move-assigns the pair from a temporary std::pair of slices. |
| constexpr | pair (const slice & key, const slice & value) noexcept Constructs the pair from the given key and value slices. |
| constexpr | pair (const stl_pair & couple) noexcept Constructs the pair from a std::pair of slices. |
| pair (const pair &) noexcept Copy constructor. |
Public Static Functions
| Type | Name |
|---|---|
| pair | invalid () noexcept Builds an invalid pair of invalid slices. |
Public Types Documentation
typedef stl_pair
An alias for std::pair< slice , slice > .
using mdbx::pair::stl_pair = std::pair<slice, slice>;
Public Attributes Documentation
variable key
The key part of the pair.
slice mdbx::pair::key;
variable value
The value part of the pair.
slice mdbx::pair::value;
Public Functions Documentation
function operator stl_pair
Converts the pair to a std::pair of slices.
inline constexpr mdbx::pair::operator stl_pair () noexcept const
Returns:
The std::pair with the same key and value.
function operator=
Copy assignment operator.
pair & mdbx::pair::operator= (
const pair &
) noexcept
Returns:
A reference to this instance.
function operator=
Move assignment operator.
inline pair & mdbx::pair::operator= (
pair && couple
) noexcept
Parameters:
coupleThe source pair to be moved from.
Returns:
A reference to this instance.
function operator=
Assigns the pair from a std::pair of slices.
inline pair & mdbx::pair::operator= (
const stl_pair & couple
)
Parameters:
coupleThe sourcestd::pair.
Returns:
A reference to this instance.
function operator=
Move-assigns the pair from a temporary std::pair of slices.
inline pair & mdbx::pair::operator= (
stl_pair && couple
)
Parameters:
coupleThe sourcestd::pairto be moved from.
Returns:
A reference to this instance.
function pair [1/3]
Constructs the pair from the given key and value slices.
inline constexpr mdbx::pair::pair (
const slice & key,
const slice & value
) noexcept
Parameters:
keyThe key part.valueThe value part.
function pair [2/3]
Constructs the pair from a std::pair of slices.
inline constexpr mdbx::pair::pair (
const stl_pair & couple
) noexcept
Parameters:
coupleThe sourcestd::pair.
function pair [3/3]
Copy constructor.
mdbx::pair::pair (
const pair &
) noexcept
Public Static Functions Documentation
function invalid
Builds an invalid pair of invalid slices.
static inline pair mdbx::pair::invalid () noexcept
Returns:
The invalid pair instance.
Friends Documentation
friend operator!=
bool mdbx::pair::operator!= (
const pair & a,
const pair & b
)
friend operator<
bool mdbx::pair::operator< (
const pair & a,
const pair & b
)
friend operator<=
bool mdbx::pair::operator<= (
const pair & a,
const pair & b
)
friend operator==
bool mdbx::pair::operator== (
const pair & a,
const pair & b
)
friend operator>
bool mdbx::pair::operator> (
const pair & a,
const pair & b
)
friend operator>=
bool mdbx::pair::operator>= (
const pair & a,
const pair & b
)
The documentation for this class was generated from the following file mdbx.h++