Dialogic Global Call IP Benutzerhandbuch

Seite von 604
INIT_IPCCLIB_START_DATA(&ipcclibstart, 2, ip_virtboard); 
INIT_IP_VIRTBOARD(&ip_virtboard[0]); 
INIT_IP_VIRTBOARD(&ip_virtboard[1]); 
ip_virtboard[0].sip_msginfo_mask = IP_SIP_MSGINFO_ENABLE | IP_SIP_MIME_ENABLE; 
ip_virtboard[1].sip_msginfo_mask = IP_SIP_MSGINFO_ENABLE | IP_SIP_MIME_ENABLE; 
ip_virtboard[0].E_SIP_OPTIONS_Access = ENUM_Enabled;
ip_virtboard[1].E_SIP_OPTIONS_Access = ENUM_Enabled;
Features that are enabled or configured via the IP_VIRTBOARD structure cannot be disabled or 
reconfigured once the library has been started. All items set in this data structure take effect when 
the gc_Start( ) function is called and remain in effect until gc_Stop( ) is called when the 
application exits. 
Note that in addition to enabling OPTIONS access, SIP message information access, and SIP 
MIME access before the virtual board is started, the application must also register the six additional 
SIP headers that it will need to access in OPTIONS-related messages it receives (Accept, Accept-
Encoding, Accept-Language, Allow, Require, and Supported). This registration is performed on a 
one-time basis after the virtual board has been started, as described in 
, on page 180, but the header field registration list can be 
updated at any time.
4.14.3
Sending OPTIONS Requests
When SIP OPTIONS access is enabled, applications use gc_Extension( ) to send the message after 
assembling the appropriate header fields and any MIME body parts in a GC_PARM_BLK. To build 
an OPTIONS request, the application uses the parameter set ID IPSET_MSG_SIP, the parameter 
ID IPPARM_MSGTYPE, and the parameter value IP_MSGTYPE_SIP_OPTIONS. 
The application can send an OPTIONS message outside of a SIP dialog by using a board device 
handle in the gc_Extension( ) call:
gc_Extension(GCTGT_GCLIB_CHAN, boarddevhandle, IPEXTID_SENDMSG, parmblkp, &retblkp, EV_ASYNC)
Alternatively, the application can send an OPTIONS request within a dialog by using the line 
device handle in the gc_Extension( ) call:
gc_Extension(GCTGT_GCLIB_CHAN, linedevhandle, IPEXTID_SENDMSG, parmblkp, &retblkp, EV_ASYNC)
When SIP OPTIONS access is enabled, the Allow header field will be the following if 
supplementary services (call transfer) is not enabled:
Allow: INVITE, CANCEL, ACK, BYE, OPTIONS
or the following if supplementary services is enabled:
Allow: INVITE, CANCEL, ACK, BYE, REFER, NOTIFY, OPTIONS
The application can add additional methods to the Allow header, but the Dialogic
®
 Global Call API 
library will ensure that all of the methods supported by the library are included.