21 #include <bsoncxx/document/view.hpp>
22 #include <bsoncxx/string/view_or_value.hpp>
23 #include <mongocxx/read_concern.hpp>
24 #include <mongocxx/read_preference.hpp>
25 #include <mongocxx/write_concern.hpp>
27 #include <mongocxx/config/prelude.hpp>
30 MONGOCXX_INLINE_NAMESPACE_BEGIN
43 class MONGOCXX_API
uri {
52 static const std::string k_default_uri;
75 uri& operator=(
uri&&) noexcept;
87 std::
string auth_mechanism() const;
94 std::
string auth_source() const;
101 std::vector<
host> hosts() const;
119 bsoncxx::document::view options() const;
126 std::
string password() const;
147 std::
string replica_set() const;
156 MONGOCXX_DEPRECATED
bool ssl() const;
177 std::
string username() const;
191 stdx::optional<stdx::string_view> appname() const;
198 stdx::optional<
bsoncxx::document::view> auth_mechanism_properties() const;
206 std::vector<stdx::string_view> compressors() const;
213 stdx::optional<std::int32_t> connect_timeout_ms() const;
220 stdx::optional<
bool> direct_connection() const;
227 stdx::optional<std::int32_t> heartbeat_frequency_ms() const;
234 stdx::optional<std::int32_t> local_threshold_ms() const;
241 stdx::optional<std::int32_t> max_pool_size() const;
248 stdx::optional<
bool> retry_reads() const;
255 stdx::optional<
bool> retry_writes() const;
262 stdx::optional<std::int32_t> server_selection_timeout_ms() const;
269 stdx::optional<
bool> server_selection_try_once() const;
276 stdx::optional<std::int32_t> socket_timeout_ms() const;
283 stdx::optional<
bool> tls_allow_invalid_certificates() const;
290 stdx::optional<
bool> tls_allow_invalid_hostnames() const;
297 stdx::optional<stdx::string_view> tls_ca_file() const;
304 stdx::optional<stdx::string_view> tls_certificate_key_file() const;
311 stdx::optional<stdx::string_view> tls_certificate_key_file_password() const;
319 stdx::optional<
bool> tls_disable_certificate_revocation_check() const;
326 stdx::optional<
bool> tls_disable_ocsp_endpoint_check() const;
333 stdx::optional<
bool> tls_insecure() const;
340 stdx::optional<std::int32_t> wait_queue_timeout_ms() const;
347 stdx::optional<std::int32_t> zlib_compression_level() const;
353 class MONGOCXX_PRIVATE impl;
355 MONGOCXX_PRIVATE
uri(std::unique_ptr<impl>&& implementation);
357 std::unique_ptr<impl> _impl;
360 MONGOCXX_INLINE_NAMESPACE_END
363 #include <mongocxx/config/postlude.hpp>