20 #include <mongocxx/client-fwd.hpp>
21 #include <mongocxx/options/auto_encryption-fwd.hpp>
22 #include <mongocxx/pool-fwd.hpp>
24 #include <bsoncxx/stdx/optional.hpp>
25 #include <mongocxx/options/pool.hpp>
26 #include <mongocxx/stdx.hpp>
27 #include <mongocxx/uri.hpp>
29 #include <mongocxx/config/prelude.hpp>
81 client* operator->() && = delete;
85 client& operator*() && = delete;
88 entry& operator=(std::nullptr_t) noexcept;
91 explicit operator
bool() const noexcept;
96 using unique_client = std::unique_ptr<
client, std::function<
void MONGOCXX_CALL(
client*)>>;
98 MONGOCXX_PRIVATE explicit
entry(unique_client);
100 unique_client _client;
116 friend ::
mongocxx::v_noabi::options::auto_encryption;
120 class MONGOCXX_PRIVATE impl;
121 const std::unique_ptr<impl> _impl;
127 #include <mongocxx/config/postlude.hpp>
Class representing a client connection to MongoDB.
Definition: client.hpp:61
Class representing the optional arguments to a MongoDB driver pool object.
Definition: pool.hpp:31
An entry is a handle on a client object acquired via the pool.
Definition: pool.hpp:77
client * operator->() const &noexcept
Access a member of the client instance.
A pool of client objects associated with a MongoDB deployment.
Definition: pool.hpp:49
pool(const uri &mongodb_uri=mongocxx::v_noabi::uri(), const options::pool &options=options::pool())
Creates a pool associated with a connection string.
stdx::optional< entry > try_acquire()
Acquires a client from the pool.
entry acquire()
Acquires a client from the pool.
Class representing a MongoDB connection string URI.
Definition: uri.hpp:47
The top-level namespace for mongocxx library entities.
Definition: bulk_write-fwd.hpp:19