]>
Commit | Line | Data |
---|---|---|
1e59de90 TL |
1 | # Civetweb API Reference |
2 | ||
3 | ### `mg_get_context_info( ctx, buffer, buflen );` | |
4 | ||
5 | ### Parameters | |
6 | ||
7 | | Parameter | Type | Description | | |
8 | | :--- | :--- | :--- | | |
9 | |**`ctx`**|`struct mg_context *`|The server context handle| | |
10 | |**`buffer`**|`char *`|A string buffer to store the information| | |
11 | |**`buflen`**|`int`|Size of the string buffer (including space for a terminating 0)| | |
12 | ||
13 | ### Return Value | |
14 | ||
15 | | Type | Description | | |
16 | | :--- | :--- | | |
17 | |`int`|Available context information in bytes (excluding the terminating 0)| | |
18 | ||
19 | ### Description | |
20 | ||
21 | The function `mg_get_context_info()` returns statistics information collected for | |
22 | the server context. This may be empty if the server has not been built with | |
23 | statistics support (`#define USE_SERVER_STATS`). | |
24 | If data is available, the returned string is in JSON format. The exact content may | |
25 | vary, depending on the server state and server version. | |
26 | ||
27 | ### See Also | |
28 | ||
29 | * [`mg_get_system_info();`](mg_get_system_info.md) | |
30 | * [`mg_get_connection_info();`](mg_get_connection_info.md) | |
31 | ||
32 |