MongoDB C++ Driver mongocxx-3.11.0
|
#include <bsoncxx/v_noabi/bsoncxx/view_or_value.hpp>
Class representing a view-or-value variant type.
Public Member Functions | |
view_or_value ()=default | |
Default-constructs a view_or_value. This is equivalent to constructing a view_or_value with a default-constructed View. | |
view_or_value (const view_or_value &other) | |
Construct a view_or_value from a copied view_or_value. | |
view_or_value (Value &&value) | |
Constructs a view_or_value from a Value type. This object owns the passed-in Value. | |
view_or_value (View view) | |
Construct a view_or_value from a View. When constructed with a View, this object is non-owning. The Value underneath the given View must outlive this object. | |
view_or_value (view_or_value &&other) noexcept | |
Construct a view_or_value from a moved-in view_or_value. | |
~view_or_value ()=default | |
Class View must be constructible from an instance of class Value. | |
bool | is_owning () const noexcept |
Return whether or not this view_or_value owns an underlying Value. | |
operator View () const | |
This type may be used as a View. | |
view_or_value & | operator= (const view_or_value &other) |
Assign to this view_or_value from a copied view_or_value. | |
view_or_value & | operator= (view_or_value &&other) noexcept |
Assign to this view_or_value from a moved-in view_or_value. | |
const View & | view () const |
Get a View for the type. | |
Related Symbols | |
(Note that these are not member symbols.) | |
template<typename View , typename Value > | |
bool | operator== (const view_or_value< View, Value > &lhs, const view_or_value< View, Value > &rhs) |
Compare view_or_value objects for (in)equality. | |
template<typename View , typename Value > | |
bool | operator!= (const view_or_value< View, Value > &lhs, const view_or_value< View, Value > &rhs) |
Compare view_or_value objects for (in)equality. | |
template<typename View , typename Value > | |
bool | operator== (const view_or_value< View, Value > &lhs, View rhs) |
Mixed (in)equality operators for view_or_value against View and Value types. | |
template<typename View , typename Value > | |
bool | operator== (View lhs, const view_or_value< View, Value > &rhs) |
Mixed (in)equality operators for view_or_value against View and Value types. | |
template<typename View , typename Value > | |
bool | operator!= (const view_or_value< View, Value > &lhs, View rhs) |
Mixed (in)equality operators for view_or_value against View and Value types. | |
template<typename View , typename Value > | |
bool | operator!= (View lhs, const view_or_value< View, Value > &rhs) |
Mixed (in)equality operators for view_or_value against View and Value types. | |
template<typename View , typename Value > | |
bool | operator== (const view_or_value< View, Value > &lhs, const Value &rhs) |
Mixed (in)equality operators for view_or_value against View and Value types. | |
template<typename View , typename Value > | |
bool | operator== (const Value &lhs, const view_or_value< View, Value > &rhs) |
Mixed (in)equality operators for view_or_value against View and Value types. | |
template<typename View , typename Value > | |
bool | operator!= (const view_or_value< View, Value > &lhs, const Value &rhs) |
Mixed (in)equality operators for view_or_value against View and Value types. | |
template<typename View , typename Value > | |
bool | operator!= (const Value &lhs, const view_or_value< View, Value > &rhs) |
Mixed (in)equality operators for view_or_value against View and Value types. | |
|
default |
Class View must be constructible from an instance of class Value.
Class View must be default constructible. Destroys a view_or_value.
|
default |
Default-constructs a view_or_value. This is equivalent to constructing a view_or_value with a default-constructed View.
|
inline |
Construct a view_or_value from a View. When constructed with a View, this object is non-owning. The Value underneath the given View must outlive this object.
view | A non-owning View. |
|
inline |
Constructs a view_or_value from a Value type. This object owns the passed-in Value.
value | A Value type. |
|
inline |
Construct a view_or_value from a copied view_or_value.
|
inlinenoexcept |
Construct a view_or_value from a moved-in view_or_value.
TODO CXX-800: Create a noexcept expression to check the conditions that must be met.
|
inlinenoexcept |
Return whether or not this view_or_value owns an underlying Value.
|
inline |
This type may be used as a View.
|
inline |
Assign to this view_or_value from a copied view_or_value.
|
inlinenoexcept |
Assign to this view_or_value from a moved-in view_or_value.
TODO CXX-800: Create a noexcept expression to check the conditions that must be met.
|
inline |
Get a View for the type.
|
related |
Mixed (in)equality operators for view_or_value against View and Value types.
|
related |
Mixed (in)equality operators for view_or_value against View and Value types.
|
related |
Compare view_or_value objects for (in)equality.
|
related |
Mixed (in)equality operators for view_or_value against View and Value types.
|
related |
Mixed (in)equality operators for view_or_value against View and Value types.
|
related |
Mixed (in)equality operators for view_or_value against View and Value types.
|
related |
Mixed (in)equality operators for view_or_value against View and Value types.
|
related |
Compare view_or_value objects for (in)equality.
|
related |
Mixed (in)equality operators for view_or_value against View and Value types.
|
related |
Mixed (in)equality operators for view_or_value against View and Value types.