The following functions are provided by the Prosody Framer API:
API call | W | Description |
---|---|---|
sm_framer_create() | Create a Framer | |
sm_framer_datafeed_connect() | Connect a datafeed to an input of a Framer . | |
sm_framer_datafeed_disconnect() | Disconnect a datafeed from a Framer. | |
sm_framer_destroy() | Destroy a Framer | |
sm_framer_get_datafeed() | Get datafeed from Framer. | |
sm_framer_get_event() | Get an event object for the Framer | |
sm_framer_status() | Fetch status info on Framer |
This document is also available as separate pages for each function.
int sm_framer_create(struct sm_framer_create_parms *createp)
typedef struct sm_framer_create_parms { tSMFramerId framer; /* out */ tSMModuleId module; /* in */ } SM_FRAMER_CREATE_PARMS;
Creates a Framer .
0 if call completed successfully, otherwise a standard error such as:
int sm_framer_datafeed_connect(struct sm_framer_datafeed_connect_parms *datafeedp)
typedef struct sm_framer_datafeed_connect_parms { tSMDatafeedId data_source; /* in */ tSMFramerId framer; /* in */ tSM_INT direction; /* in */ } SM_FRAMER_DATAFEED_CONNECT_PARMS;
Connect a datafeed to one of the inputs of the Framer.
0 if call completed successfully, otherwise a standard error such as:
int sm_framer_datafeed_disconnect(struct sm_framer_datafeed_disconnect_parms *datafeedp)
typedef struct sm_framer_datafeed_disconnect_parms { tSMFramerId framer; /* in */ tSM_INT direction; /* in */ } SM_FRAMER_DATAFEED_DISCONNECT_PARMS;
Disconnect a datafeed on one of the inputs of the Framer.
0 if call completed successfully, otherwise a standard error such as:
int sm_framer_destroy(tSMFramerId framer)
Destroys a Framer.
0 if call completed successfully, otherwise a standard error such as:
int sm_framer_get_datafeed(struct sm_framer_datafeed_parms *datafeedp)
typedef struct sm_framer_datafeed_parms { tSMFramerId framer; /* in */ tSM_INT direction; /* in */ tSMDatafeedId datafeed; /* out */ } SM_FRAMER_DATAFEED_PARMS;
Request a datafeed identifier from a Framer . This identifier can subsequently used in a call such as sm_tdmtx_datafeed_connect() or sm_channel_datafeed_connect().
0 if call completed successfully, otherwise a standard error such as:
int sm_framer_get_event(struct sm_framer_event_parms *eventp)
typedef struct sm_framer_event_parms { tSMFramerId framer; /* in */ tSMEventId event; /* out */ } SM_FRAMER_EVENT_PARMS;
Returns an event object for the framer that can be waited on using smd_ev_wait() . The event will be signalled when a status change occurs on the framer.
0 if call completed successfully, otherwise a standard error such as:
int sm_framer_status(struct sm_framer_status_parms *statusp)
typedef struct sm_framer_status_parms { tSMFramerId framer; /* in */ enum kSMFramerStatus { kSMFramerStatusRunning, kSMFramerStatusStopped, kSMFramerStatusNewState, } status; /* out */ tSM_INT new_state; /* out */ } SM_FRAMER_STATUS_PARMS;
Returns the status of the Framer.
0 if call completed successfully, otherwise a standard error such as:
These functions constitute the Prosody Framer API.