resource_asterisk.h 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. /*
  2. * Asterisk -- An open source telephony toolkit.
  3. *
  4. * Copyright (C) 2012 - 2013, Digium, Inc.
  5. *
  6. * David M. Lee, II <dlee@digium.com>
  7. *
  8. * See http://www.asterisk.org for more information about
  9. * the Asterisk project. Please do not directly contact
  10. * any of the maintainers of this project for assistance;
  11. * the project provides a web site, mailing lists and IRC
  12. * channels for your use.
  13. *
  14. * This program is free software, distributed under the terms of
  15. * the GNU General Public License Version 2. See the LICENSE file
  16. * at the top of the source tree.
  17. */
  18. /*! \file
  19. *
  20. * \brief Generated file - declares stubs to be implemented in
  21. * res/ari/resource_asterisk.c
  22. *
  23. * Asterisk resources
  24. *
  25. * \author David M. Lee, II <dlee@digium.com>
  26. */
  27. /*
  28. * !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  29. * !!!!! DO NOT EDIT !!!!!
  30. * !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  31. * This file is generated by a mustache template. Please see the original
  32. * template in rest-api-templates/ari_resource.h.mustache
  33. */
  34. #ifndef _ASTERISK_RESOURCE_ASTERISK_H
  35. #define _ASTERISK_RESOURCE_ASTERISK_H
  36. #include "asterisk/ari.h"
  37. /*! Argument struct for ast_ari_asterisk_get_info() */
  38. struct ast_ari_asterisk_get_info_args {
  39. /*! Array of Filter information returned */
  40. const char **only;
  41. /*! Length of only array. */
  42. size_t only_count;
  43. /*! Parsing context for only. */
  44. char *only_parse;
  45. };
  46. /*!
  47. * \brief Body parsing function for /asterisk/info.
  48. * \param body The JSON body from which to parse parameters.
  49. * \param[out] args The args structure to parse into.
  50. * \retval zero on success
  51. * \retval non-zero on failure
  52. */
  53. int ast_ari_asterisk_get_info_parse_body(
  54. struct ast_json *body,
  55. struct ast_ari_asterisk_get_info_args *args);
  56. /*!
  57. * \brief Gets Asterisk system information.
  58. *
  59. * \param headers HTTP headers
  60. * \param args Swagger parameters
  61. * \param[out] response HTTP response
  62. */
  63. void ast_ari_asterisk_get_info(struct ast_variable *headers, struct ast_ari_asterisk_get_info_args *args, struct ast_ari_response *response);
  64. /*! Argument struct for ast_ari_asterisk_get_global_var() */
  65. struct ast_ari_asterisk_get_global_var_args {
  66. /*! The variable to get */
  67. const char *variable;
  68. };
  69. /*!
  70. * \brief Body parsing function for /asterisk/variable.
  71. * \param body The JSON body from which to parse parameters.
  72. * \param[out] args The args structure to parse into.
  73. * \retval zero on success
  74. * \retval non-zero on failure
  75. */
  76. int ast_ari_asterisk_get_global_var_parse_body(
  77. struct ast_json *body,
  78. struct ast_ari_asterisk_get_global_var_args *args);
  79. /*!
  80. * \brief Get the value of a global variable.
  81. *
  82. * \param headers HTTP headers
  83. * \param args Swagger parameters
  84. * \param[out] response HTTP response
  85. */
  86. void ast_ari_asterisk_get_global_var(struct ast_variable *headers, struct ast_ari_asterisk_get_global_var_args *args, struct ast_ari_response *response);
  87. /*! Argument struct for ast_ari_asterisk_set_global_var() */
  88. struct ast_ari_asterisk_set_global_var_args {
  89. /*! The variable to set */
  90. const char *variable;
  91. /*! The value to set the variable to */
  92. const char *value;
  93. };
  94. /*!
  95. * \brief Body parsing function for /asterisk/variable.
  96. * \param body The JSON body from which to parse parameters.
  97. * \param[out] args The args structure to parse into.
  98. * \retval zero on success
  99. * \retval non-zero on failure
  100. */
  101. int ast_ari_asterisk_set_global_var_parse_body(
  102. struct ast_json *body,
  103. struct ast_ari_asterisk_set_global_var_args *args);
  104. /*!
  105. * \brief Set the value of a global variable.
  106. *
  107. * \param headers HTTP headers
  108. * \param args Swagger parameters
  109. * \param[out] response HTTP response
  110. */
  111. void ast_ari_asterisk_set_global_var(struct ast_variable *headers, struct ast_ari_asterisk_set_global_var_args *args, struct ast_ari_response *response);
  112. #endif /* _ASTERISK_RESOURCE_ASTERISK_H */