summaryrefslogtreecommitdiff
path: root/pjsip/include/pjsip/sip_transport.h
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2006-09-14 16:07:49 +0000
committerBenny Prijono <bennylp@teluu.com>2006-09-14 16:07:49 +0000
commite015ebe064c6f5120ef2af2b73ce52796a06f790 (patch)
tree0b3ed8be366ec88d571195568bb2aa6002f2e18b /pjsip/include/pjsip/sip_transport.h
parentf5ee360b0b649ef24fe671b6e37006badce0634d (diff)
Added pjsip_transport_register_type() API to register new transport type.
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@720 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjsip/include/pjsip/sip_transport.h')
-rw-r--r--pjsip/include/pjsip/sip_transport.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/pjsip/include/pjsip/sip_transport.h b/pjsip/include/pjsip/sip_transport.h
index 69a9f624..ec371f0f 100644
--- a/pjsip/include/pjsip/sip_transport.h
+++ b/pjsip/include/pjsip/sip_transport.h
@@ -80,6 +80,30 @@ enum pjsip_transport_flags_e
((tp)->flag & PJSIP_TRANSPORT_SECURE)
/**
+ * Register new transport type to PJSIP. The PJSIP transport framework
+ * contains the info for some standard transports, as declared by
+ * #pjsip_transport_type_e. Application may use non-standard transport
+ * with PJSIP, but before it does so, it must register the information
+ * about the new transport type to PJSIP by calling this function.
+ *
+ * @param tp_flag The flags describing characteristics of this
+ * transport type.
+ * @param tp_name Transport type name.
+ * @param def_port Default port to be used for the transport.
+ * @param p_tp_type On successful registration, it will be filled with
+ * the registered type. This argument is optional.
+ *
+ * @return PJ_SUCCESS if registration is successful, or
+ * PJSIP_ETYPEEXISTS if the same transport type has
+ * already been registered.
+ */
+PJ_DECL(pj_status_t) pjsip_transport_register_type(unsigned tp_flag,
+ const char *tp_name,
+ int def_port,
+ int *p_tp_type);
+
+
+/**
* Get the transport type from the transport name.
*
* @param name Transport name, such as "TCP", or "UDP".