How to use a MongoDB C++ Driver instance.
Initialize the C++ Driver
Basic Usage
Errors
Instance Recreation
void example() {
{
try {
EXPECT(false && "should not reach this point");
EXPECT(ex.code() == mongocxx::error_code::k_cannot_recreate_instance);
}
}
}
Destroyed Instance
void example() {
{
}
try {
EXPECT(false && "should not reach this point");
EXPECT(ex.code() == mongocxx::error_code::k_cannot_recreate_instance);
}
try {
EXPECT(false && "should not reach this point");
EXPECT(ex.code() == mongocxx::error_code::k_cannot_recreate_instance);
}
}