#include <mongocxx/v_noabi/mongocxx/instance.hpp>
An instance of the MongoDB C++ Driver.
- Attention
- This feature is experimental! It is not ready for use!
All mongocxx API MUST be used within the lifetime of the instance object, with special exemptions listed below. Only ONE instance object may exist for the lifetime of a given process. It is undefined behavior to use the mongocxx API before the instance object is initialized or after the instance object is destroyed. It is undefined behavior to create more than one instance object.
int main() {
{
}
}
An instance of the MongoDB C++ Driver.
Definition instance.hpp:66
instance()
Creates an instance of the driver.
- Special exemptions
- Only the following API are permitted to be used outside the lifetime of an instance object:
- See also
-
◆ instance() [1/4]
| mongocxx::v_noabi::instance::instance |
( |
| ) |
|
Creates an instance of the driver.
◆ instance() [2/4]
| mongocxx::v_noabi::instance::instance |
( |
std::unique_ptr< v_noabi::logger > | logger | ) |
|
Creates an instance of the driver with a user provided log handler.
- Parameters
-
| logger | The logger that the driver will direct log messages to. |
- Exceptions
-
◆ instance() [3/4]
| mongocxx::v_noabi::instance::instance |
( |
instance && | other | ) |
|
|
noexcept |
Move constructs an instance of the driver.
- Postconditions:
- other is in an assign-or-destroy-only state.
◆ ~instance()
| mongocxx::v_noabi::instance::~instance |
( |
| ) |
|
Destroys an instance of the driver.
◆ instance() [4/4]
| mongocxx::v_noabi::instance::instance |
( |
instance const & | | ) |
|
|
delete |
This class is not copyable.
◆ current()
| instance & mongocxx::v_noabi::instance::current |
( |
| ) |
|
|
static |
- Warning
- For internal use only!
◆ operator=() [1/2]
Move assigns an instance of the driver.
- Postconditions:
- other is in an assign-or-destroy-only state.
◆ operator=() [2/2]
This class is not copyable.
The documentation for this class was generated from the following file: