[asterisk-commits] mmichelson: branch group/CCSS r212994 - /team/group/CCSS/include/asterisk/ccss.h

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Aug 18 17:24:41 CDT 2009


Author: mmichelson
Date: Tue Aug 18 17:24:35 2009
New Revision: 212994

URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=212994
Log:
Initialization, copy, and check for if an option is a cc parameter.


Modified:
    team/group/CCSS/include/asterisk/ccss.h

Modified: team/group/CCSS/include/asterisk/ccss.h
URL: http://svn.asterisk.org/svn-view/asterisk/team/group/CCSS/include/asterisk/ccss.h?view=diff&rev=212994&r1=212993&r2=212994
==============================================================================
--- team/group/CCSS/include/asterisk/ccss.h (original)
+++ team/group/CCSS/include/asterisk/ccss.h Tue Aug 18 17:24:35 2009
@@ -86,11 +86,11 @@
  * \brief The various possibilities for cc_agent_policy values
  */
 enum ast_ccss_agent_policies {
-	/* Never offer CCSS to the caller */
+	/*! Never offer CCSS to the caller */
 	AST_CCSS_AGENT_NEVER,
-	/* Offer CCSS using native signaling */
+	/*! Offer CCSS using native signaling */
 	AST_CCSS_AGENT_NATIVE,
-	/* Use generic agent for caller */
+	/*! Use generic agent for caller */
 	AST_CCSS_AGENT_GENERIC,
 };
 
@@ -99,16 +99,16 @@
  * \brief The various possibilities for cc_monitor_policy values
  */
 enum ast_ccss_monitor_policies {
-	/* Never accept CCSS offers from callee */
+	/*! Never accept CCSS offers from callee */
 	AST_CCSS_MONITOR_NEVER,
 	/* CCSS only available if callee offers it through signaling */
 	AST_CCSS_MONITOR_NATIVE,
-	/* Always use CCSS generic monitor for callee
+	/*! Always use CCSS generic monitor for callee
 	 * Note that if callee offers CCSS natively, we still
 	 * will use a generic CCSS monitor if this is set
 	 */
 	AST_CCSS_MONITOR_GENERIC,
-	/* Accept native CCSS offers, but if no offer is present,
+	/*! Accept native CCSS offers, but if no offer is present,
 	 * use a generic CCSS monitor
 	 */
 	AST_CCSS_MONITOR_ALWAYS,
@@ -116,6 +116,41 @@
 
 /* Forward declaration. Struct is in main/ccss.c */
 struct ast_cc_config_params;
+
+/*!
+ * \brief Allocate and initialize an ast_cc_config_params structure
+ *
+ * Reasonable default values are chosen for the parameters upon allocation.
+ *
+ * \retval NULL Unable to allocate the structure
+ * \retval non-NULL A pointer to the newly allocated and initialized structure
+ */
+struct ast_cc_config_params *ast_cc_config_params_init(void);
+
+/*!
+ * \since 1.6.4
+ * \brief Is this a CCSS configuration parameter?
+ * \param name Name of configuration option being parsed.
+ * \retval 1 Yes, this is a CCSS configuration parameter.
+ * \retval 0 No, this is not a CCSS configuration parameter.
+ */
+int ast_ccss_is_cc_config_param(const char * const name);
+
+/*!
+ * \since 1.6.4
+ * \brief copy CCSS configuration parameters from one structure to another
+ *
+ * For now, this is a simple memcpy, but this function is necessary since
+ * the size of an ast_cc_config_params structure is unknown outside of
+ * main/ccss.c. Also, this allows for easier expansion of the function in
+ * case it becomes more complex than just a memcpy.
+ *
+ * \param src The structure from which data is copied
+ * \param dest The structure to which data is copied
+ * \retval -1 Copy failed (no way for this to happen yet)
+ * \retval 0 Copy succeeded
+ */
+void ast_ccss_copy_config_params(struct ast_cc_config_params *dest, const struct ast_cc_config_params *src);
 
 /*!
  * \since 1.6.4




More information about the asterisk-commits mailing list