mongoc_topology_description_get_servers() — MongoDB C Driver 1.6.3

- MongoDB C Driver 1.6.3 »
- API Reference »
- mongoc_topology_description_t

# mongoc_topology_description_get_servers()

## Synopsis

    mongoc_server_description_t **
    mongoc_topology_description_get_servers (
       const mongoc_topology_description_t *td, size_t *n);

Fetches an array of mongoc_server_description_t structs for all known servers in the topology.

## Parameters

- `td`: A mongoc_topology_description_t.
- `n`: Receives the length of the descriptions array.

## Returns

A newly allocated array that must be freed with mongoc_server_descriptions_destroy_all().

Created using Sphinx 1.5.3, based on Sphinx Readable Theme.