|
MongoDB C++ Driver
mongocxx-3.0.1
|
Class representing an instance of the MongoDB driver. More...
#include <instance.hpp>
Public Member Functions | |
| instance () | |
| Creates an instance of the driver. | |
| instance (std::unique_ptr< logger > logger) | |
| Creates an instance of the driver with a user provided log handler. More... | |
| instance (instance &&) noexcept | |
| Move constructs an instance of the driver. | |
| instance & | operator= (instance &&) noexcept |
| Move assigns an instance of the driver. | |
| ~instance () | |
| Destroys an instance of the driver. | |
Static Public Member Functions | |
| static instance & | current () |
| Returns the current unique instance of the driver. More... | |
Class representing an instance of the MongoDB driver.
Life cycle: A unique instance of the driver MUST be kept around.
| mongocxx::instance::instance | ( | std::unique_ptr< logger > | logger | ) |
Creates an instance of the driver with a user provided log handler.
| logger | The logger that the driver will direct log messages to. |
|
static |
Returns the current unique instance of the driver.
If an instance was explicitly created, that will be returned. If no instance has yet been created, a default instance will be constructed and returned.
1.8.10