Changeset 4275 for pjproject/trunk/pjsip/include/pjsip/sip_endpoint.h
- Timestamp:
- Oct 4, 2012 6:11:58 AM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjsip/include/pjsip/sip_endpoint.h
r4154 r4275 214 214 pjsip_module *module ); 215 215 216 /** 217 * This describes additional parameters to pjsip_endpt_process_rx_data() 218 * function. Application MUST call pjsip_process_rdata_param_default() to 219 * initialize this structure. 220 */ 221 typedef struct pjsip_process_rdata_param 222 { 223 /** 224 * Specify the minimum priority number of the modules that are allowed 225 * to process the message. Default is zero to allow all modules to 226 * process the message. 227 */ 228 unsigned start_prio; 229 230 /** 231 * Specify the pointer of the module where processing will start. 232 * The default is NULL, meaning processing will start from the start 233 * of the module list. 234 */ 235 void *start_mod; 236 237 /** 238 * Set to N, then processing will start at Nth module after start 239 * module (where start module can be an explicit module as specified 240 * by \a start_mod or the start of module list when \a start_mod is 241 * NULL). For example, if set to 1, then processing will start from 242 * the next module after start module. Default is zero. 243 */ 244 unsigned idx_after_start; 245 246 /** 247 * Print nothing to log. Default is PJ_FALSE. 248 */ 249 pj_bool_t silent; 250 251 } pjsip_process_rdata_param; 252 253 /** 254 * Initialize with default. 255 * 256 * @param p The param. 257 */ 258 PJ_DECL(void) pjsip_process_rdata_param_default(pjsip_process_rdata_param *p); 259 260 /** 261 * Manually distribute the specified pjsip_rx_data to registered modules. 262 * Normally application does not need to call this function because received 263 * messages will be given to endpoint automatically by transports. 264 * 265 * Application can use this function when it has postponed the processing of 266 * an incoming message, for example to perform long operations such as 267 * database operation or to consult other servers to decide what to do with 268 * the message. In this case, application clones the original rdata, return 269 * from the callback, and perform the long operation. Upon completing the 270 * long operation, it resumes pjsip's module processing by calling this 271 * function, and then free the cloned rdata. 272 * 273 * @param endpt The endpoint instance. 274 * @param rdata The rdata to be distributed. 275 * @param p Optional pointer to param to specify from which module 276 * the processing should start. 277 * @param p_handled Optional pointer to receive last return value of 278 * module's \a on_rx_request() or \a on_rx_response() 279 * callback. 280 * 281 * @return PJ_SUCCESS on success. 282 */ 283 PJ_DECL(pj_status_t) pjsip_endpt_process_rx_data(pjsip_endpoint *endpt, 284 pjsip_rx_data *rdata, 285 pjsip_process_rdata_param *p, 286 pj_bool_t *p_handled); 216 287 217 288 /**
Note: See TracChangeset
for help on using the changeset viewer.