zdk.objc
Instance Methods | Properties | List of all members
<ZDKContextConfiguration> Protocol Reference

General ZDK/Context configuration. More...

#import <ZDKContextConfiguration.h>

Inheritance diagram for <ZDKContextConfiguration>:
<ZDKZHandle>

Instance Methods

(NSString *) - handlesDescription
 
- Instance Methods inherited from <ZDKZHandle>
(long int) - handle
 
(void) - initialize
 
(void) - releaseReference
 
(NSString *) - handlesDescription
 

Properties

int sipUdpPort
 Sets the requested SIP UDP port to be used. More...
 
int sipUdpPortInUse
 Gets the actually used SIP UDP port. More...
 
int sipTcpPort
 Sets the requested SIP TCP port to be used. More...
 
int sipTcpPortInUse
 Gets the actually used SIP TCP port. More...
 
int sipTlsPort
 Sets the requested SIP TCP port to be used. More...
 
int sipTlsPortInUse
 Gets the actually used SIP TLS port. More...
 
int iaxUdpPortInUse
 Gets the actually used IAX UDP port. More...
 
int rtpPort
 Sets the base port to be used for RTP streams. More...
 
BOOL enableIPv6
 Sets the global use of ZDKPv6 support. More...
 
ZDKIpVersionType ipVersionPreference
 Selects the preferred IP version. More...
 
NSString *_Nullable userSipInstance
 Generate a random UUID to be used for SIP user instance. More...
 
BOOL enableSIPReliableProvisioning
 Sets the global usage of reliable provisional as described in RFC 3262. More...
 
NSString *_Nullable userAgent
 Sets the ZDK's user agent. More...
 
int mediaDSCP
 Configures the DSCP for the media streams. More...
 
int signalDSCP
 Configures the DSCP for the signaling streams. More...
 
NSString *_Nullable rtpSessionName
 Configures the RTP session name for the SDP. More...
 
NSString *_Nullable rtpUsername
 Configures the RTP user name for the SDP. More...
 
NSString *_Nullable rtpUrl
 Configures the URL for SDP. More...
 
NSString *_Nullable rtpEmail
 Configures the e-mail address for SDP. More...
 

Detailed Description

General ZDK/Context configuration.

The configuration is applied with startContext()! Any changes after startContext() has been invoked will not take effect until a restart happens - stopContext() followed by startContext().

Method Documentation

◆ handlesDescription

- (NSString *) handlesDescription

Reimplemented from <ZDKZHandle>.

Property Documentation

◆ enableIPv6

- (BOOL) enableIPv6
readwritenonatomicassign

Sets the global use of ZDKPv6 support.

Globally enable ZDKPv6 support. Once enabled all networking will still try to go through ZDKPv4 first, if possible, before trying ZDKPv6. The ZDKPv6 will be used as a backup in case ZDKPv4 is either not available or inaccessible.

Parameters
[in]value
  • 0 - disabled
  • 1 - enabled

◆ enableSIPReliableProvisioning

- (BOOL) enableSIPReliableProvisioning
readwritenonatomicassign

Sets the global usage of reliable provisional as described in RFC 3262.

The reliability mechanism works by mirroring the current reliability mechanisms for 2xx final responses to ZDKNVITE. The PRACK request plays the same role as ACK, but for provisional responses. There is an important difference, however. PRACK is a normal SIP message, like BYE. As such, its own reliability is ensured hop-by-hop through each stateful proxy. Also like BYE, but unlike ACK, PRACK has its own response.

Extending the Session Initiation Protocol (SIP) - RFC 3262.

Parameters
[in]value
  • 0 - disabled
  • 1 - enabled

◆ iaxUdpPortInUse

- (int) iaxUdpPortInUse
readnonatomicassign

Gets the actually used IAX UDP port.

In case the requested port was already taken the next available one will be opened. !!! Works ONLY AFTER zdkContext::AddProtocol() !!!

Returns
The local UDP port for IAX. "-1" in case of not initialized or error!

◆ ipVersionPreference

- (ZDKIpVersionType) ipVersionPreference
readwritenonatomicassign

Selects the preferred IP version.

Selects which IP version to prefer when resolving DNS.

If ZDKPv6 is selected, but not available/enabled, will fallback to the default "Automatic".

Parameters
[in]valueThe desired preference
See also
IpVersionType

◆ mediaDSCP

- (int) mediaDSCP
readwritenonatomicassign

Configures the DSCP for the media streams.

This will affect the RTP, SRTP and ZDKAX2 sockets. Might require administrative privileges.

Parameters
[in]valueThe DiffServ Code Point
See also
signalDSCP()

◆ rtpEmail

- (NSString* _Nullable) rtpEmail
readwritenonatomicassign

Configures the e-mail address for SDP.

Sets the email address to put in SDP offers/answers. This is optional.

Parameters
[in]valueThe e-mail address
See also
rtpPort(), rtpSessionName(), rtpUsername(), rtpUrl()

◆ rtpPort

- (int) rtpPort
readwritenonatomicassign

Sets the base port to be used for RTP streams.

Set the base UDP port to use for RTP streams. Default is 8000.

Each call uses two UDP ports, one for the actual audio stream and another one for the control (RTCP) packets.

A free port will be searched for from that base upwards for each call. When the call is finished the port will be reused in the future.

Use the value of 0 to use an OS-assigned random port.

Parameters
[in]valueThe RTP port base, or 0 for random port to be used

◆ rtpSessionName

- (NSString* _Nullable) rtpSessionName
readwritenonatomicassign

Configures the RTP session name for the SDP.

Sets the RTP session name for the SDP offers/answers. The name should not contain spaces.

Parameters
[in]valueRTP session name
See also
rtpPort(), rtpUsername(), rtpUrl(), rtpEmail()

◆ rtpUrl

- (NSString* _Nullable) rtpUrl
readwritenonatomicassign

Configures the URL for SDP.

Sets the URL for the SDP offers/answers. This is optional.

Parameters
[in]valueThe URL
See also
rtpPort(), rtpSessionName(), rtpUsername(), rtpEmail()

◆ rtpUsername

- (NSString* _Nullable) rtpUsername
readwritenonatomicassign

Configures the RTP user name for the SDP.

Sets the RTP user name for the SDP offers/answers. The user name should not contain spaces.

Parameters
[in]valueRTP user name
See also
rtpPort(), rtpSessionName(), rtpUrl(), rtpEmail()

◆ signalDSCP

- (int) signalDSCP
readwritenonatomicassign

Configures the DSCP for the signaling streams.

This will affect the SIP sockets (UDP, TCP and TLS).

Parameters
[in]valueThe DiffServ Code Point
See also
mediaDSCP()

◆ sipTcpPort

- (int) sipTcpPort
readwritenonatomicassign

Sets the requested SIP TCP port to be used.

In case the requested port was already taken the next available one will be opened.

Use the value of -1 to try to open the same as UDP (default). Use the value of 0 to use an OS-assigned random port.

Parameters
[in]valueThe requested local TCP port for SIP TCP to be used
See also
sipUdpPort(), sipUdpPortInUse(), sipTcpPortInUse(), sipTlsPort(), sipTlsPortInUse()

◆ sipTcpPortInUse

- (int) sipTcpPortInUse
readnonatomicassign

Gets the actually used SIP TCP port.

In case the requested port was already taken the next available one will be opened. Default is the sipUdpPort. !!! Works ONLY AFTER startContext() !!!

Returns
The local TCP port for SIP TCP. "-1" in case of not initialized or error!
See also
sipUdpPort(), sipUdpPortInUse(), sipTcpPort(), sipTlsPort(), sipTlsPortInUse()

◆ sipTlsPort

- (int) sipTlsPort
readwritenonatomicassign

Sets the requested SIP TCP port to be used.

In case the requested port was already taken the next available one will be opened.

Use the value of -1 to try to open the next available port after the TCP one (sipTcpPort+1) (default). Use the value of 0 to use an OS-assigned random port.

Parameters
[in]valueThe requested local TCP port for SIP TLS to be used (not a mistake, TLS run on top of TCP)
See also
sipUdpPort(), sipUdpPortInUse(), sipTcpPort(), sipTcpPortInUse(), sipTlsPortInUse()

◆ sipTlsPortInUse

- (int) sipTlsPortInUse
readnonatomicassign

Gets the actually used SIP TLS port.

In case the requested port was already taken the next available one will be opened. Default is the sipTcpPort+1. !!! Works ONLY AFTER startContext() !!!

Returns
The local TCP port for SIP TLS (not a mistake, TLS run on top of TCP). "-1" in case of not initialized or error!
See also
sipUdpPort(), sipUdpPortInUse(), sipTcpPort(), sipTcpPortInUse(), sipTlsPort()

◆ sipUdpPort

- (int) sipUdpPort
readwritenonatomicassign

Sets the requested SIP UDP port to be used.

In case the requested port was already taken the next available one will be opened. Default is 5060.

Use the value of 0 to use an OS-assigned random port.

Parameters
[in]valueThe requested local UDP port for SIP UDP to be used, or 0 for random port to be used
See also
sipUdpPortInUse(), sipTcpPort(), sipTcpPortInUse(), sipTlsPort(), sipTlsPortInUse()

◆ sipUdpPortInUse

- (int) sipUdpPortInUse
readnonatomicassign

Gets the actually used SIP UDP port.

In case the requested port was already taken the next available one will be opened. Default is the sipUdpPort. !!! Works ONLY AFTER startContext() !!!

Returns
The local UDP port for SIP UDP. "-1" in case of not initialized or error!
See also
sipUdpPort(), sipTcpPort(), sipTcpPortInUse(), sipTlsPort(), sipTlsPortInUse()

◆ userAgent

- (NSString* _Nullable) userAgent
readwritenonatomicassign

Sets the ZDK's user agent.

Used in SIP messages mainly. (User-Agent header field).

Parameters
[in]valueUTF-8 encoded user agent

◆ userSipInstance

- (NSString* _Nullable) userSipInstance
readnonatomicassign

Generate a random UUID to be used for SIP user instance.

Generates a valid RFC 4122 (RFC 2141) UUID URN that can be used for RFC 5626 (SIP Outbound).

The result is a string in the format "urn:uuid:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx". The prefix is there for easier use of sipInstance().

Returns
Generated UUID URN
See also
sipInstance()

The documentation for this protocol was generated from the following file: