|
StreamLinkforC
7.0.3-308369
|
![]() |
Data Structures | |
| struct | sl_commandlistener |
| Defines the interface that should be satisfied to receive information on publishing success and failure. More... | |
Typedefs | |
| typedef struct sl_subscription_s | sl_command |
| Opaque handle that represents a (persistent) command. | |
Enumerations |
Functions | |
| void | sl_cancel_persistence (streamlink *client, sl_command *sub) |
| Cancel persistence for a command. More... | |
| sl_command * | sl_publish (streamlink *client, const char *subject, sl_fieldlist *fields, sl_commandlistener *listener, void *ctx) |
| Publish information for a given subject. More... | |
| sl_command * | sl_publish_bytime (streamlink *client, const char *subject, time_t bytime, sl_fieldlist *fields, sl_commandlistener *listener, void *ctx) |
| Publish information for a given subject. More... | |
| sl_command * | sl_publish_persist (streamlink *client, const char *subject, sl_command_persistence persist_mode, sl_fieldlist *fields, sl_commandlistener *listener, void *ctx) |
| Publish information for a given subject. More... | |
| void sl_cancel_persistence | ( | streamlink * | client, |
| sl_command * | sub | ||
| ) |
Cancel persistence for a command.
| client | - The StreamLink client |
| sub | - The subscription to unsubscribe from |
| sl_command* sl_publish | ( | streamlink * | client, |
| const char * | subject, | ||
| sl_fieldlist * | fields, | ||
| sl_commandlistener * | listener, | ||
| void * | ctx | ||
| ) |
Publish information for a given subject.
| client | - The StreamLink client |
| subject | - The subject to publish information to |
| fields | - A collection of field and value data to publish |
| listener | - A listener which will receive success/failure messages for this publishing attemp |
| ctx | - User callback context which will passed to the listener |
| sl_command* sl_publish_bytime | ( | streamlink * | client, |
| const char * | subject, | ||
| time_t | bytime, | ||
| sl_fieldlist * | fields, | ||
| sl_commandlistener * | listener, | ||
| void * | ctx | ||
| ) |
Publish information for a given subject.
| client | - The StreamLink client |
| subject | - The subject to publish information to |
| bytime | - The time by which the message should be published |
| fields | - A collection of field and value data to publish |
| listener | - A listener which will receive success/failure messages for this publishing attemp |
| ctx | - User callback context which will passed to the listener |
This method can be used to implement time sensitive contributions. If bytime has passed, the publish message won't be sent to the Liberator and a sl_ERROR_CANCELLED will passed to the supplied listener.
| sl_command* sl_publish_persist | ( | streamlink * | client, |
| const char * | subject, | ||
| sl_command_persistence | persist_mode, | ||
| sl_fieldlist * | fields, | ||
| sl_commandlistener * | listener, | ||
| void * | ctx | ||
| ) |
Publish information for a given subject.
| client | - The StreamLink client |
| subject | - The subject to publish information to |
| persist_mode | - The persistence mode |
| fields | - A collection of field and value data to publish |
| listener | - A listener which will receive success/failure messages for this publishing attemp |
| ctx | - User callback context which will passed to the listener |
This function can be used to ensure that the publication takes place when StreamLink reconnects to the Liberator. Typical use cases might be to implement "On-Behalf-Of" behaviour.