aboutsummaryrefslogtreecommitdiffstats
path: root/include/asterisk/dial.h
diff options
context:
space:
mode:
authorfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2007-07-30 20:42:28 +0000
committerfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2007-07-30 20:42:28 +0000
commitc3f03b34444ec12eb2a7fcef062b070bfe48f876 (patch)
treeca11a043297f47f84bcffd22b7253a6e5bc0da8a /include/asterisk/dial.h
parentb6354a43bbae4b1bc684c74f0a62ea6963ca9561 (diff)
Add support for call forwarding and timeouts to the dialing API.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@77801 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'include/asterisk/dial.h')
-rw-r--r--include/asterisk/dial.h24
1 files changed, 20 insertions, 4 deletions
diff --git a/include/asterisk/dial.h b/include/asterisk/dial.h
index dd3604556..9a2478070 100644
--- a/include/asterisk/dial.h
+++ b/include/asterisk/dial.h
@@ -37,10 +37,11 @@ typedef void (*ast_dial_state_callback)(struct ast_dial *);
/*! \brief List of options that are applicable either globally or per dialed channel */
enum ast_dial_option {
- AST_DIAL_OPTION_RINGING, /*!< Always indicate ringing to caller */
- AST_DIAL_OPTION_ANSWER_EXEC, /*!< Execute application upon answer in async mode */
- AST_DIAL_OPTION_MUSIC, /*!< Play music on hold instead of ringing to the calling channel */
- AST_DIAL_OPTION_MAX, /*!< End terminator -- must always remain last */
+ AST_DIAL_OPTION_RINGING, /*!< Always indicate ringing to caller */
+ AST_DIAL_OPTION_ANSWER_EXEC, /*!< Execute application upon answer in async mode */
+ AST_DIAL_OPTION_MUSIC, /*!< Play music on hold instead of ringing to the calling channel */
+ AST_DIAL_OPTION_DISABLE_CALL_FORWARDING, /*!< Disable call forwarding on channels */
+ AST_DIAL_OPTION_MAX, /*!< End terminator -- must always remain last */
};
/*! \brief List of return codes for dial run API calls */
@@ -145,6 +146,21 @@ int ast_dial_option_disable(struct ast_dial *dial, int num, enum ast_dial_option
*/
void ast_dial_set_state_callback(struct ast_dial *dial, ast_dial_state_callback callback);
+/*! \brief Set the maximum time (globally) allowed for trying to ring phones
+ * \param dial The dial structure to apply the time limit to
+ * \param timeout Maximum time allowed
+ * \return nothing
+ */
+void ast_dial_set_global_timeout(struct ast_dial *dial, int timeout);
+
+/*! \brief Set the maximum time (per channel) allowed for trying to ring the phone
+ * \param dial The dial structure the channel belongs to
+ * \param num Channel number to set timeout on
+ * \param timeout Maximum time allowed
+ * \return nothing
+ */
+void ast_dial_set_timeout(struct ast_dial *dial, int num, int timeout);
+
#if defined(__cplusplus) || defined(c_plusplus)
}
#endif