dialplan_functions.h 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. /*
  2. * Asterisk -- An open source telephony toolkit.
  3. *
  4. * Copyright (C) 2013, Digium, Inc.
  5. *
  6. * See http://www.asterisk.org for more information about
  7. * the Asterisk project. Please do not directly contact
  8. * any of the maintainers of this project for assistance;
  9. * the project provides a web site, mailing lists and IRC
  10. * channels for your use.
  11. *
  12. * This program is free software, distributed under the terms of
  13. * the GNU General Public License Version 2. See the LICENSE file
  14. * at the top of the source tree.
  15. */
  16. /*!
  17. * \file
  18. * \brief PJSIP dialplan functions header file
  19. */
  20. #ifndef _PJSIP_DIALPLAN_FUNCTIONS
  21. #define _PJSIP_DIALPLAN_FUNCTIONS
  22. /*!
  23. * \brief CHANNEL function read callback
  24. * \param chan The channel the function is called on
  25. * \param cmd The name of the function
  26. * \param data Arguments passed to the function
  27. * \param buf Out buffer that should be populated with the data
  28. * \param len Size of the buffer
  29. *
  30. * \retval 0 on success
  31. * \retval -1 on failure
  32. */
  33. int pjsip_acf_channel_read(struct ast_channel *chan, const char *cmd, char *data, char *buf, size_t len);
  34. /*!
  35. * \brief PJSIP_MEDIA_OFFER function write callback
  36. * \param chan The channel the function is called on
  37. * \param cmd The name of the function
  38. * \param data Arguments passed to the function
  39. * \param value Value to be set by the function
  40. *
  41. * \retval 0 on success
  42. * \retval -1 on failure
  43. */
  44. int pjsip_acf_media_offer_write(struct ast_channel *chan, const char *cmd, char *data, const char *value);
  45. /*!
  46. * \brief PJSIP_DTMF_MODE function read callback
  47. * \param chan The channel the function is called on
  48. * \param cmd The name of the function
  49. * \param data Arguments passed to the function
  50. * \param buf Out buffer that should be populated with the data
  51. * \param len Size of the buffer
  52. *
  53. * \retval 0 on success
  54. * \retval -1 on failure
  55. */
  56. int pjsip_acf_dtmf_mode_read(struct ast_channel *chan, const char *cmd, char *data, char *buf, size_t len);
  57. /*!
  58. * \brief PJSIP_DTMF_MODE function write callback
  59. * \param chan The channel the function is called on
  60. * \param cmd The name of the function
  61. * \param data Arguments passed to the function
  62. * \param value Value to be set by the function
  63. *
  64. * \retval 0 on success
  65. * \retval -1 on failure
  66. */
  67. int pjsip_acf_dtmf_mode_write(struct ast_channel *chan, const char *cmd, char *data, const char *value);
  68. /*!
  69. * \brief PJSIP_MEDIA_OFFER function read callback
  70. * \param chan The channel the function is called on
  71. * \param cmd The name of the function
  72. * \param data Arguments passed to the function
  73. * \param buf Out buffer that should be populated with the data
  74. * \param len Size of the buffer
  75. *
  76. * \retval 0 on success
  77. * \retval -1 on failure
  78. */
  79. int pjsip_acf_media_offer_read(struct ast_channel *chan, const char *cmd, char *data, char *buf, size_t len);
  80. /*!
  81. * \brief PJSIP_SEND_SESSION_REFRESH function write callback
  82. * \param chan The channel the function is called on
  83. * \param cmd the Name of the function
  84. * \param data Arguments passed to the function
  85. * \param value Value to be set by the function
  86. *
  87. * \retval 0 on success
  88. * \retval -1 on failure
  89. */
  90. int pjsip_acf_session_refresh_write(struct ast_channel *chan, const char *cmd, char *data, const char *value);
  91. /*!
  92. * \brief PJSIP_DIAL_CONTACTS function read callback
  93. * \param chan The channel the function is called on
  94. * \param cmd The name of the function
  95. * \param data Arguments passed to the function
  96. * \param buf Out buffer that should be populated with the data
  97. * \param len Size of the buffer
  98. *
  99. * \retval 0 on success
  100. * \retval -1 on failure
  101. */
  102. int pjsip_acf_dial_contacts_read(struct ast_channel *chan, const char *cmd, char *data, char *buf, size_t len);
  103. /*!
  104. * \brief PJSIP_PARSE_URI function read callback
  105. * \param chan The channel the function is called on
  106. * \param cmd The name of the function
  107. * \param data Arguments passed to the function
  108. * \param buf Out buffer that should be populated with the data
  109. * \param len Size of the buffer
  110. *
  111. * \retval 0 on success
  112. * \retval -1 on failure
  113. */
  114. int pjsip_acf_parse_uri_read(struct ast_channel *chan, const char *cmd, char *data, char *buf, size_t len);
  115. #endif /* _PJSIP_DIALPLAN_FUNCTIONS */