CEL refactoring cleanup

This change removes AST_CEL_BRIDGE_UPDATE since it should no longer be
used because masquerade situations are now accounted for in other ways.

This also refactors usage of AST_CEL_FORWARD to be produced by a Dial
message which has been extended with a "forward" field.

(closes issue ASTERISK-21566)
Review: https://reviewboard.asterisk.org/r/2635/


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@392829 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Kinsey Moore
2013-06-25 13:03:17 +00:00
parent 13b470d704
commit a1e219ef51
7 changed files with 161 additions and 27 deletions

View File

@@ -83,8 +83,6 @@ enum ast_cel_event_type {
AST_CEL_USER_DEFINED = 21,
/*! \brief the last channel with the given linkedid is retired */
AST_CEL_LINKEDID_END = 22,
/*! \brief a masquerade happened to alter the participants on a bridge */
AST_CEL_BRIDGE_UPDATE = 23,
/*! \brief a directed pickup was performed on this channel */
AST_CEL_PICKUP = 24,
/*! \brief this call was forwarded somewhere else */
@@ -245,6 +243,26 @@ struct ast_cel_event_record {
*/
int ast_cel_fill_record(const struct ast_event *event, struct ast_cel_event_record *r);
/*!
* \brief Publish a CEL event
* \since 12
*
* \param chan This is the primary channel associated with this channel event.
* \param event_type This is the type of call event being reported.
* \param blob This contains any additional parameters that need to be conveyed for this event.
*/
void ast_cel_publish_event(struct ast_channel *chan,
enum ast_cel_event_type event_type,
struct ast_json *blob);
/*!
* \brief Get the CEL topic
*
* \retval The CEL topic
* \retval NULL if not allocated
*/
struct stasis_topic *ast_cel_topic(void);
#if defined(__cplusplus) || defined(c_plusplus)
}
#endif

View File

@@ -454,6 +454,24 @@ void ast_channel_publish_dial(struct ast_channel *caller,
const char *dialstring,
const char *dialstatus);
/*!
* \since 12
* \brief Publish in the \ref ast_channel_topic or \ref ast_channel_topic_all
* topics a stasis message for the channels involved in a dial operation that
* is forwarded.
*
* \param caller The channel performing the dial operation
* \param peer The channel being dialed
* \param dialstring The information passed to the dialing application when beginning a dial
* \param dialstatus The current status of the dial operation
* \param forward The call forward string provided by the dialed channel
*/
void ast_channel_publish_dial_forward(struct ast_channel *caller,
struct ast_channel *peer,
const char *dialstring,
const char *dialstatus,
const char *forward);
/*!
* \since 12
* \brief Publish in the \ref ast_channel_topic a \ref ast_channel_snapshot