BLOG | DOCUMENTATION | TRAC

Home --> Documentations --> PJSIP Reference

Representation of events as they are distributed among modules. More...

Data Structures

struct  pjsip_event
 

Macros

#define PJSIP_EVENT_INIT_TIMER(event, pentry)
 
#define PJSIP_EVENT_INIT_TSX_STATE(event, ptsx, ptype, pdata, prev)
 
#define PJSIP_EVENT_INIT_TX_MSG(event, ptdata)
 
#define PJSIP_EVENT_INIT_RX_MSG(event, prdata)
 
#define PJSIP_EVENT_INIT_TRANSPORT_ERROR(event, ptsx, ptdata)
 
#define PJSIP_EVENT_INIT_USER(event, u1, u2, u3, u4)
 

Enumerations

enum  pjsip_event_id_e {
  PJSIP_EVENT_UNKNOWN, PJSIP_EVENT_TIMER, PJSIP_EVENT_TX_MSG, PJSIP_EVENT_RX_MSG,
  PJSIP_EVENT_TRANSPORT_ERROR, PJSIP_EVENT_TSX_STATE, PJSIP_EVENT_USER
}
 

Functions

const char * pjsip_event_str (pjsip_event_id_e e)
 

Detailed Description

Macro Definition Documentation

#define PJSIP_EVENT_INIT_TIMER (   event,
  pentry 
)
Value:
do { \
(event).type = PJSIP_EVENT_TIMER; \
(event).body.timer.entry = pentry; \
} while (0)
pjsip_hdr_e type
Definition: sip_msg.h:326
Definition: sip_event.h:49

Init timer event.

#define PJSIP_EVENT_INIT_TSX_STATE (   event,
  ptsx,
  ptype,
  pdata,
  prev 
)
Value:
do { \
(event).body.tsx_state.tsx = ptsx; \
(event).body.tsx_state.type = ptype; \
(event).body.tsx_state.src.data = pdata; \
(event).body.tsx_state.prev_state = prev; \
} while (0)
pjsip_hdr_e type
Definition: sip_msg.h:326
Definition: sip_event.h:61

Init tsx state event.

#define PJSIP_EVENT_INIT_TX_MSG (   event,
  ptdata 
)
Value:
do { \
(event).type = PJSIP_EVENT_TX_MSG; \
(event).body.tx_msg.tdata = ptdata; \
} while (0)
pjsip_hdr_e type
Definition: sip_msg.h:326
Definition: sip_event.h:52

Init tx msg event.

#define PJSIP_EVENT_INIT_RX_MSG (   event,
  prdata 
)
Value:
do { \
(event).type = PJSIP_EVENT_RX_MSG; \
(event).body.rx_msg.rdata = prdata; \
} while (0)
pjsip_hdr_e type
Definition: sip_msg.h:326
Definition: sip_event.h:55

Init rx msg event.

#define PJSIP_EVENT_INIT_TRANSPORT_ERROR (   event,
  ptsx,
  ptdata 
)
Value:
do { \
(event).body.tx_error.tsx = ptsx; \
(event).body.tx_error.tdata = ptdata; \
} while (0)
Definition: sip_event.h:58
pjsip_hdr_e type
Definition: sip_msg.h:326

Init transport error event.

#define PJSIP_EVENT_INIT_USER (   event,
  u1,
  u2,
  u3,
  u4 
)
Value:
do { \
(event).type = PJSIP_EVENT_USER; \
(event).body.user.user1 = (void*)u1; \
(event).body.user.user2 = (void*)u2; \
(event).body.user.user3 = (void*)u3; \
(event).body.user.user4 = (void*)u4; \
} while (0)
Definition: sip_event.h:64
pjsip_hdr_e type
Definition: sip_msg.h:326

Init user event.

Enumeration Type Documentation

Event IDs.

Enumerator
PJSIP_EVENT_UNKNOWN 

Unidentified event.

PJSIP_EVENT_TIMER 

Timer event, normally only used internally in transaction.

PJSIP_EVENT_TX_MSG 

Message transmission event.

PJSIP_EVENT_RX_MSG 

Message received event.

PJSIP_EVENT_TRANSPORT_ERROR 

Transport error event.

PJSIP_EVENT_TSX_STATE 

Transaction state changed event.

PJSIP_EVENT_USER 

Indicates that the event was triggered by user action.

Function Documentation

const char* pjsip_event_str ( pjsip_event_id_e  e)

Get the event string from the event ID.

Parameters
ethe event ID.
Note
defined in sip_util.c

 


PJSIP Open Source, high performance, small footprint, and very very portable SIP stack
Copyright (C) 2006-2008 Teluu Inc.