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

ZDK's main entry point. More...

#import <ZDKContext.h>

Inheritance diagram for <ZDKContext>:
<ZDKZHandle>

Instance Methods

(id< ZDKResult >) - startContext
 Initialize the ZDK. More...
 
(id< ZDKResult >) - stopContext
 Destroys the ZDK. More...
 
(id< ZDKResult >) - addProto:col:
 Creates a call manager instance for a protocol. More...
 
(id< ZDKResult >) - testSIPURI:
 
(void) - setStatusListener:
 Configures the context event listener. More...
 
(id< ZDKResult >) - networkChanged
 Notify the ZDK for changed network event. More...
 
(void) - forceNativeCrash:
 Force native crash. More...
 
(NSString *) - handlesDescription
 
- Instance Methods inherited from <ZDKZHandle>
(long int) - handle
 
(void) - initialize
 
(void) - releaseReference
 
(NSString *) - handlesDescription
 

Properties

BOOL contextRunning
 Returnes whether the context is running and functional. More...
 
id< ZDKCallsProvidercallsProvider
 Gets the active calls information provider. More...
 
id< ZDKAccountProvideraccountProvider
 Gets the account information and control provider. More...
 
id< ZDKConferenceProviderconferenceProvider
 Gets the conference controlling helper. More...
 
id< ZDKDNSRequestProviderdnsRequestProvider
 Gets the DNS resolving requests provider. More...
 
id< ZDKContextConfigurationconfiguration
 Gets the general ZDK/Context configuration. More...
 
id< ZDKEncryptionConfigurationencryptionConfiguration
 Gets the encription specific configuration. More...
 
id< ZDKAudioEndpointControlaudioControls
 Gets the audio endpoint's main entry point. More...
 
id< ZDKVideoEndpointControlvideoControls
 Gets the video endpoint's main entry point. More...
 
id< ZDKRingBackToneControlringback
 Ringback tone's main entry point. More...
 
id< ZDKActivationactivation
 Gets the ZDK's Activation process handler. More...
 
id< ZDKLoglogger
 Gets the ZDK's debug logging facility instance. More...
 
id< ZDKProxyManagerproxyManager
 Gets the ZDK's proxy manager. More...
 
id< ZDKBanafoManagerbanafoManager
 Gets the ZDK's Banafo manager. More...
 
NSString * libraryVersion
 Get the ZDK version. More...
 

Detailed Description

ZDK's main entry point.

Method Documentation

◆ addProto:col:

- (id< ZDKResult >) addProto: (ZDKProtocolType)  proto
col: (int)  port 

Creates a call manager instance for a protocol.

Creates a call manager instance for a specific protocol.

Protocol MUST be added before creating accounts using it!

Will be automatically destroyed by stopContext.

Some call managers are automatically created by startContext. SIP cannot be created by this function.

Parameters
[in]protoProtocol
[in]portPort at which to bind the main socket, or 0 for random port to be used
Returns
Result of the addition
See also
ProtocolType, ZDKResult

◆ forceNativeCrash:

- (void) forceNativeCrash: (unsigned int)  delayMs

Force native crash.

Forces a native crash to take place.

Parameters
[in]delayMsDelay in milliseconds. If 0 - crashes immediately!

◆ handlesDescription

- (NSString *) handlesDescription

Reimplemented from <ZDKZHandle>.

◆ networkChanged

- (id< ZDKResult >) networkChanged

Notify the ZDK for changed network event.

Handles the network change event - resets the DNS, re-register users, refreshes active calls, etc.

Each invocation restarts a timer delaying the execution of the handling with 500ms from the last received event - if invoked more then once in the delay period, the handling will happen 500ms after the last call.

Returns
Result of the invocation
See also
ZDKResult

◆ setStatusListener:

- (void) setStatusListener: (id< ZDKContextEventsHandler >)  value

Configures the context event listener.

The set listener will be notified for each event.

Parameters
[in]valueThe context event listener to be added
See also
ZDKContextEventsHandler

◆ startContext

- (id< ZDKResult >) startContext

Initialize the ZDK.

Create all internal structures, protocol stacks, network transports and event queues. It will test the available audio devices. It will spawn necessary processing threads. You must call stopContext to close the network transports, stop all threads and free all structures.

Do not call this function more than once in a row - use stopContext to clean up and then you can call startContext again.

Returns
Result of the initialization
See also
- stopContext, ZDKResult

◆ stopContext

- (id< ZDKResult >) stopContext

Destroys the ZDK.

Closes network transports, terminates worker threads and frees all structures. You can call startContext after this to re-open the library.

This is a blocking call and will always take some time to finish but has a hard-limit of 2 seconds for IAX and 4 seconds for SIP which in the worst case means 6-7 seconds with some additional time for thread synchronisation.

Returns
Result of the initialization
See also
- startContext, ZDKResult

Property Documentation

◆ accountProvider

- (id<ZDKAccountProvider>) accountProvider
readnonatomicassign

Gets the account information and control provider.

Manages creation and destruction of user accounts and provides information regarding them.

Returns
The account provider
See also
ZDKAccountProvider

◆ activation

- (id<ZDKActivation>) activation
readnonatomicassign

Gets the ZDK's Activation process handler.

Returns
The activation handler
See also
ZDKActivation

◆ audioControls

- (id<ZDKAudioEndpointControl>) audioControls
readnonatomicassign

Gets the audio endpoint's main entry point.

Entry point for controlling the audio endpoint

Returns
The audio endpoint control
See also
ZDKAudioEndpointControl

◆ banafoManager

- (id<ZDKBanafoManager>) banafoManager
readnonatomicassign

Gets the ZDK's Banafo manager.

Returns
The ZDK's Banafo manager instance
See also
ZDKBanafoManager

◆ callsProvider

- (id<ZDKCallsProvider>) callsProvider
readnonatomicassign

Gets the active calls information provider.

Returns
The calls provider
See also
ZDKCallsProvider

◆ conferenceProvider

- (id<ZDKConferenceProvider>) conferenceProvider
readnonatomicassign

Gets the conference controlling helper.

Returns
The conference provider
See also
ZDKConferenceProvider

◆ configuration

- (id<ZDKContextConfiguration>) configuration
readnonatomicassign

Gets the 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.

Returns
The context configuration
See also
ZDKContextConfiguration

◆ contextRunning

- (BOOL) contextRunning
readnonatomicassign

Returnes whether the context is running and functional.

Returns
Context's running state

◆ dnsRequestProvider

- (id<ZDKDNSRequestProvider>) dnsRequestProvider
readnonatomicassign

Gets the DNS resolving requests provider.

Returns
The DNS resolving requests provider
See also
ZDKDNSRequestProvider

◆ encryptionConfiguration

- (id<ZDKEncryptionConfiguration>) encryptionConfiguration
readnonatomicassign

Gets the encription specific configuration.

Returns
The encription configuration
See also
ZDKEncryptionConfiguration

◆ libraryVersion

- (NSString*) libraryVersion
readnonatomicassign

Get the ZDK version.

Get the revision of the ZDK's source last commit.

Returns
The revision as an ASCII string.

◆ logger

- (id<ZDKLog>) logger
readnonatomicassign

Gets the ZDK's debug logging facility instance.

Only a single instance of the debug logging facility is created and returned during the life time of the library.

Returns
The ZDK's debug logging facility instance
See also
ZDKLog

◆ proxyManager

- (id<ZDKProxyManager>) proxyManager
readnonatomicassign

Gets the ZDK's proxy manager.

Returns
The ZDK's proxy manager instance
See also
ZDKProxyManager

◆ ringback

- (id<ZDKRingBackToneControl>) ringback
readnonatomicassign

Ringback tone's main entry point.

Entry point for controlling the ringback tone heard by the user when the remote peer starts ringing

Returns
The ringback tone control
See also
ZDKRingBackToneControl

◆ videoControls

- (id<ZDKVideoEndpointControl>) videoControls
readnonatomicassign

Gets the video endpoint's main entry point.

Entry point for controlling the video endpoint

Returns
The video endpoint control
See also
ZDKVideoEndpointControl

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