1MONGOC_URI_SET_USERNAME(3) libmongoc MONGOC_URI_SET_USERNAME(3)
2
3
4
6 mongoc_uri_set_username - mongoc_uri_set_username()
7
9 bool
10 mongoc_uri_set_username (mongoc_uri_t *uri, const char *username);
11
13 • uri: A mongoc_uri_t.
14
15 • username: The new username.
16
18 Sets the URI's username, after the URI has been parsed from a string.
19 The driver authenticates with this username if the password is also
20 set.
21
23 Returns false if the option cannot be set, for example if username is
24 not valid UTF-8.
25
27 MongoDB, Inc
28
30 2017-present, MongoDB, Inc
31
32
33
34
351.24.3 Aug 17, 2023 MONGOC_URI_SET_USERNAME(3)