zdk.net
Public Member Functions | Public Attributes | Properties | List of all members
ZDK_NET::ContextConfiguration Class Reference

General ZDK/Context configuration. More...

#include <ContextConfiguration.h>

Inheritance diagram for ZDK_NET::ContextConfiguration:
ZDK_NET::ZHandle

Public Member Functions

 ContextConfiguration (ZDK::Shared::ContextConfiguration src)
 
virtual long long Handle () override
 
virtual void Initialize () override
 
virtual void ReleaseReference () override
 

Public Attributes

ZDK::IContextConfiguration * cppRef = nullptr
 

Properties

int SIPUdpPort [get, set]
 Sets the requested SIP UDP port to be used. More...
 
int SIPUdpPortInUse [get]
 Gets the actually used SIP UDP port. More...
 
int SIPTcpPort [get, set]
 Sets the requested SIP TCP port to be used. More...
 
int SIPTcpPortInUse [get]
 Gets the actually used SIP TCP port. More...
 
int SIPTlsPort [get, set]
 Sets the requested SIP TCP port to be used. More...
 
int SIPTlsPortInUse [get]
 Gets the actually used SIP TLS port. More...
 
int IAXUdpPortInUse [get]
 Gets the actually used IAX UDP port. More...
 
int RTPPort [get, set]
 Sets the base port to be used for RTP streams. More...
 
bool EnableIPv6 [get, set]
 Sets the global use of Pv6 support. More...
 
ZDK_NET::IpVersionType IpVersionPreference [get, set]
 Selects the preferred IP version. More...
 
System::String^ UserSipInstance [get]
 Generate a random UUID to be used for SIP user instance. More...
 
bool EnableSIPReliableProvisioning [get, set]
 Sets the global usage of reliable provisional as described in RFC 3262. More...
 
System::String^ UserAgent [get, set]
 Sets the ZDK's user agent. More...
 
int MediaDSCP [get, set]
 Configures the DSCP for the media streams. More...
 
int SignalDSCP [get, set]
 Configures the DSCP for the signaling streams. More...
 
System::String^ RTPSessionName [get, set]
 Configures the RTP session name for the SDP. More...
 
System::String^ RTPUsername [get, set]
 Configures the RTP user name for the SDP. More...
 
System::String^ RTPUrl [get, set]
 Configures the URL for SDP. More...
 
System::String^ RTPEmail [get, set]
 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().

Property Documentation

◆ EnableIPv6

bool ZDK_NET::ContextConfiguration::EnableIPv6
getset

Sets the global use of Pv6 support.

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

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

◆ EnableSIPReliableProvisioning

bool ZDK_NET::ContextConfiguration::EnableSIPReliableProvisioning
getset

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 NVITE. 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 ZDK_NET::ContextConfiguration::IAXUdpPortInUse
get

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 Context::AddProtocol() !!!

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

◆ IpVersionPreference

ZDK_NET:: IpVersionType ZDK_NET::ContextConfiguration::IpVersionPreference
getset

Selects the preferred IP version.

Selects which IP version to prefer when resolving DNS.

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

Parameters
[in]valueThe desired preference
See also
IpVersionType

◆ MediaDSCP

int ZDK_NET::ContextConfiguration::MediaDSCP
getset

Configures the DSCP for the media streams.

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

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

◆ RTPEmail

System:: String^ ZDK_NET::ContextConfiguration::RTPEmail
getset

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 ZDK_NET::ContextConfiguration::RTPPort
getset

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

System:: String^ ZDK_NET::ContextConfiguration::RTPSessionName
getset

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

System:: String^ ZDK_NET::ContextConfiguration::RTPUrl
getset

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

System:: String^ ZDK_NET::ContextConfiguration::RTPUsername
getset

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 ZDK_NET::ContextConfiguration::SignalDSCP
getset

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 ZDK_NET::ContextConfiguration::SIPTcpPort
getset

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 ZDK_NET::ContextConfiguration::SIPTcpPortInUse
get

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 ZDK_NET::ContextConfiguration::SIPTlsPort
getset

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 ZDK_NET::ContextConfiguration::SIPTlsPortInUse
get

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 ZDK_NET::ContextConfiguration::SIPUdpPort
getset

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 ZDK_NET::ContextConfiguration::SIPUdpPortInUse
get

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

System:: String^ ZDK_NET::ContextConfiguration::UserAgent
getset

Sets the ZDK's user agent.

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

Parameters
[in]valueUTF-8 encoded user agent

◆ UserSipInstance

System:: String^ ZDK_NET::ContextConfiguration::UserSipInstance
get

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 class was generated from the following file: