Ignore:
Timestamp:
Dec 30, 2005 11:50:15 PM (18 years ago)
Author:
bennylp
Message:

Basic module, transport, and sending messages

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip/include/pjsip/sip_endpoint.h

    r105 r106  
    116116                                         const pj_time_val *max_timeout); 
    117117 
     118 
     119/** 
     120 * Schedule timer to endpoint's timer heap. Application must poll the endpoint 
     121 * periodically (by calling #pjsip_endpt_handle_events) to ensure that the 
     122 * timer events are handled in timely manner. When the timeout for the timer 
     123 * has elapsed, the callback specified in the entry argument will be called. 
     124 * This function, like all other endpoint functions, is thread safe. 
     125 * 
     126 * @param endpt     The endpoint. 
     127 * @param entry     The timer entry. 
     128 * @param delay     The relative delay of the timer. 
     129 * @return          PJ_OK (zero) if successfull. 
     130 */ 
     131PJ_DECL(pj_status_t) pjsip_endpt_schedule_timer( pjsip_endpoint *endpt, 
     132                                                 pj_timer_entry *entry, 
     133                                                 const pj_time_val *delay ); 
     134 
     135/** 
     136 * Cancel the previously registered timer. 
     137 * This function, like all other endpoint functions, is thread safe. 
     138 * 
     139 * @param endpt     The endpoint. 
     140 * @param entry     The timer entry previously registered. 
     141 */ 
     142PJ_DECL(void) pjsip_endpt_cancel_timer( pjsip_endpoint *endpt,  
     143                                        pj_timer_entry *entry ); 
     144 
     145 
    118146/** 
    119147 * Dump endpoint status to the log. This will print the status to the log 
     
    126154 */ 
    127155PJ_DECL(void) pjsip_endpt_dump( pjsip_endpoint *endpt, pj_bool_t detail ); 
     156 
     157 
     158/** 
     159 * Register new module to the endpoint. 
     160 * The endpoint will then call the load and start function in the module to  
     161 * properly initialize the module, and assign a unique module ID for the  
     162 * module. 
     163 * 
     164 * @param endpt         The endpoint. 
     165 * @param module        The module to be registered. 
     166 * 
     167 * @return              PJ_SUCCESS on success. 
     168 */ 
     169PJ_DECL(pj_status_t) pjsip_endpt_register_module( pjsip_endpoint *endpt, 
     170                                                  pjsip_module *module ); 
     171 
     172/** 
     173 * Unregister a module from the endpoint. 
     174 * The endpoint will then call the stop and unload function in the module to  
     175 * properly shutdown the module. 
     176 * 
     177 * @param endpt         The endpoint. 
     178 * @param module        The module to be registered. 
     179 * 
     180 * @return              PJ_SUCCESS on success. 
     181 */ 
     182PJ_DECL(pj_status_t) pjsip_endpt_unregister_module( pjsip_endpoint *endpt, 
     183                                                    pjsip_module *module ); 
     184 
    128185 
    129186/** 
     
    157214 
    158215/** 
    159  * Schedule timer to endpoint's timer heap. Application must poll the endpoint 
    160  * periodically (by calling #pjsip_endpt_handle_events) to ensure that the 
    161  * timer events are handled in timely manner. When the timeout for the timer 
    162  * has elapsed, the callback specified in the entry argument will be called. 
    163  * This function, like all other endpoint functions, is thread safe. 
    164  * 
    165  * @param endpt     The endpoint. 
    166  * @param entry     The timer entry. 
    167  * @param delay     The relative delay of the timer. 
    168  * @return          PJ_OK (zero) if successfull. 
    169  */ 
    170 PJ_DECL(pj_status_t) pjsip_endpt_schedule_timer( pjsip_endpoint *endpt, 
    171                                                  pj_timer_entry *entry, 
    172                                                  const pj_time_val *delay ); 
    173  
    174 /** 
    175  * Cancel the previously registered timer. 
    176  * This function, like all other endpoint functions, is thread safe. 
    177  * 
    178  * @param endpt     The endpoint. 
    179  * @param entry     The timer entry previously registered. 
    180  */ 
    181 PJ_DECL(void) pjsip_endpt_cancel_timer( pjsip_endpoint *endpt,  
    182                                         pj_timer_entry *entry ); 
    183  
    184 /** 
    185216 * Create a new transaction. After creating the transaction, application MUST 
    186217 * initialize the transaction as either UAC or UAS (by calling 
     
    279310 * @see pjsip_transport_get 
    280311 */ 
    281 PJ_DECL(pj_status_t) pjsip_endpt_alloc_transport( pjsip_endpoint *endpt, 
    282                                                   pjsip_transport_type_e type, 
    283                                                   const pj_sockaddr *remote, 
    284                                                   int addr_len, 
    285                                                   pjsip_transport **p_transport); 
     312PJ_DECL(pj_status_t)  
     313pjsip_endpt_acquire_transport( pjsip_endpoint *endpt, 
     314                               pjsip_transport_type_e type, 
     315                               const pj_sockaddr_t *remote, 
     316                               int addr_len, 
     317                               pjsip_transport **p_transport); 
    286318 
    287319/** 
Note: See TracChangeset for help on using the changeset viewer.