1MONGOC_CLIENT_GET_DATABASE_NAMES(3)libmongocMONGOC_CLIENT_GET_DATABASE_NAMES(3)
2
3
4
6 mongoc_client_get_database_names - mongoc_client_get_database_names()
7
9 char **
10 mongoc_client_get_database_names (mongoc_client_t *client, bson_error_t *error)
11 BSON_GNUC_WARN_UNUSED_RESULT
12 BSON_GNUC_DEPRECATED_FOR (mongoc_client_get_database_names_with_opts);
13
15 This function is deprecated and should not be used in new code.
16
17 Please use mongoc_client_get_database_names_with_opts() instead.
18
20 This function queries the MongoDB server for a list of known databases.
21
22 This function is considered a retryable read operation. Upon a tran‐
23 sient error (a network error, errors due to replica set failover, etc.)
24 the operation is safely retried once. If retryreads is false in the
25 URI (see mongoc_uri_t) the retry behavior does not apply.
26
28 • client: A mongoc_client_t.
29
30 • error: An optional location for a bson_error_t or NULL.
31
33 Errors are propagated via the error parameter.
34
36 A NULL terminated vector of NULL-byte terminated strings. The result
37 should be freed with bson_strfreev().
38
39 NULL is returned upon failure and error is set.
40
42 MongoDB, Inc
43
45 2017-present, MongoDB, Inc
46
47
48
49
501.23.1 Oct 20, 202M2ONGOC_CLIENT_GET_DATABASE_NAMES(3)