ARI: Add support for getting/setting channel and global variables.

This allows for reading and writing of functions on channels.

(closes issue ASTERISK-21868)

Review: https://reviewboard.asterisk.org/r/2641/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@393806 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Jason Parker
2013-07-08 14:46:20 +00:00
parent 7422581b6d
commit 87973eecff
10 changed files with 478 additions and 4 deletions

View File

@@ -173,6 +173,25 @@ int stasis_app_control_continue(struct stasis_app_control *control, const char *
*/
int stasis_app_control_answer(struct stasis_app_control *control);
/*!
* \brief Get the value of a variable on the channel associated with this control.
* \param control Control for \c res_stasis.
* \param variable The name of the variable.
* \return The value of the variable. The returned variable must be freed.
*/
char *stasis_app_control_get_channel_var(struct stasis_app_control *control, const char *variable);
/*!
* \brief Set a variable on the channel associated with this control to value.
* \param control Control for \c res_stasis.
* \param variable The name of the variable
* \param value The value to set the variable to
*
* \return 0 for success.
* \return -1 for error.
*/
int stasis_app_control_set_channel_var(struct stasis_app_control *control, const char *variable, const char *value);
/*!
* \brief Place the channel associated with the control on hold.
* \param control Control for \c res_stasis.