File espos_httpd_sse.h¶
FileList > espos_httpd > include > espos_httpd_sse.h
Go to the source code of this file
#include <stdbool.h>#include "esp_err.h"
Public Types¶
| Type | Name |
|---|---|
| typedef void(* | espos_httpd_sse_connect_cb_t Called (on the server task) each time a client connects, so a component can push its current snapshot to just that client. |
Public Functions¶
| Type | Name |
|---|---|
| int | espos_httpd_sse_client_count (void) |
| esp_err_t | espos_httpd_sse_on_connect (espos_httpd_sse_connect_cb_t cb, void * arg) |
| esp_err_t | espos_httpd_sse_publish (const char * event, const char * json) Broadcast to every connected client. |
| esp_err_t | espos_httpd_sse_send (int client, const char * event, const char * json) Send to one client (valid inside an on-connect callback). |
Public Types Documentation¶
typedef espos_httpd_sse_connect_cb_t¶
Called (on the server task) each time a client connects, so a component can push its current snapshot to just that client.
Small fixed table.
Public Functions Documentation¶
function espos_httpd_sse_client_count¶
function espos_httpd_sse_on_connect¶
function espos_httpd_sse_publish¶
Broadcast to every connected client.
Returns ESP_OK even with 0 clients.
function espos_httpd_sse_send¶
Send to one client (valid inside an on-connect callback).
The documentation for this class was generated from the following file espos_httpd/include/espos_httpd_sse.h