Core
public class Core : LinphoneObject
Main object to instanciate and on which to keep a reference.
This object is the first object to instanciante, and will allow you to perform
all kind of tasks. To create it, use either Factory.createCore() or
Factory.createCoreWithConfig(), see Config
for more information about factory
and default config. On some platforms like Android or iOS you will need to give
it the Context of your application.
Once the Core
is in state Ready
, use start(). It will then go to state On
and from that you can start using it for calls and chat messages. It is
recommended to add a LinphoneCoreCbs listener using linphone_core_add_listener
to it to monitor different events.
To be able to receive events from the network, you must schedule a call
iterate() often, like every 20ms. On Android & iOS isAutoIterateEnabled() is
enabled by default so you don’t have to worry about that unless you disable it
using linphone_core_set_auto_iterate_enabled or by setting in the [misc]
section of your configuration auto_iterate=0. - Warning: Our API isn’t
thread-safe but also isn’t blocking, so it is strongly recommend to always call
our methods from the main thread.
Once you don’t need it anymore, call stop() and release the reference on it so
it can gracefully shutdown.
-
Undocumented
Declaration
Swift
public static func getSwiftObject(cObject: OpaquePointer) -> Core
-
Undocumented
Declaration
Swift
public var getCobject: OpaquePointer? { get }
-
Undocumented
Declaration
Swift
public var nativeVideoWindow: UIView? { get set }
-
-
Undocumented
Declaration
Swift
public var nativePreviewWindow: UIView? { get set }
-
-
Used to notify if log collection upload have been succesfully delivered or not.
See moreDeclaration
Swift
public enum LogCollectionUploadState : Int
-
Main object to instanciate and on which to keep a reference. This object is the first object to instanciante, and will allow you to perform all kind of tasks. To create it, use either Factory.createCore() or Factory.createCoreWithConfig(), see
Config
for more information about factory and default config. On some platforms like Android or iOS you will need to give it the Context of your application. Once theCore
is in stateReady
, use start(). It will then go to stateOn
and from that you can start using it for calls and chat messages. It is recommended to add a LinphoneCoreCbs listener using linphone_core_add_listener to it to monitor different events. To be able to receive events from the network, you must schedule a call iterate() often, like every 20ms. On Android & iOS isAutoIterateEnabled() is enabled by default so you don’t have to worry about that unless you disable it using linphone_core_set_auto_iterate_enabled or by setting in the [misc] section of your configuration auto_iterate=0. - Warning: Our API isn’t thread-safe but also isn’t blocking, so it is strongly recommend to always call our methods from the main thread. Once you don’t need it anymore, call stop() and release the reference on it so it can gracefully shutdown.Declaration
Swift
public func addDelegate(delegate: CoreDelegate)
-
Main object to instanciate and on which to keep a reference. This object is the first object to instanciante, and will allow you to perform all kind of tasks. To create it, use either Factory.createCore() or Factory.createCoreWithConfig(), see
Config
for more information about factory and default config. On some platforms like Android or iOS you will need to give it the Context of your application. Once theCore
is in stateReady
, use start(). It will then go to stateOn
and from that you can start using it for calls and chat messages. It is recommended to add a LinphoneCoreCbs listener using linphone_core_add_listener to it to monitor different events. To be able to receive events from the network, you must schedule a call iterate() often, like every 20ms. On Android & iOS isAutoIterateEnabled() is enabled by default so you don’t have to worry about that unless you disable it using linphone_core_set_auto_iterate_enabled or by setting in the [misc] section of your configuration auto_iterate=0. - Warning: Our API isn’t thread-safe but also isn’t blocking, so it is strongly recommend to always call our methods from the main thread. Once you don’t need it anymore, call stop() and release the reference on it so it can gracefully shutdown.Declaration
Swift
public func removeDelegate(delegate: CoreDelegate)
-
Compress the log collection in a single file.
Declaration
Swift
public static func compressLogCollection() -> String
Return Value
The path of the compressed log collection file (to be freed calling ms_free()).
-
Enable the linphone core log collection to upload logs on a server.
Declaration
Swift
public static func enableLogCollection(state: LogCollectionState)
Parameters
state
LogCollectionState
value telling whether to enable log collection or not. -
Get the max file size in bytes of the files used for log collection.
Declaration
Swift
public static var getLogCollectionMaxFileSize: Int { get }
Return Value
The max file size in bytes of the files used for log collection.
-
Get the path where the log files will be written for log collection.
Declaration
Swift
public static var getLogCollectionPath: String { get }
Return Value
The path where the log files will be written.
-
Get the prefix of the filenames that will be used for log collection.
Declaration
Swift
public static var getLogCollectionPrefix: String { get }
Return Value
The prefix of the filenames used for log collection.
-
Returns liblinphone’s version as a string.
Declaration
Swift
public static var getVersion: String { get }
Return Value
the current version of the
Core
-
Tells whether the linphone core log collection is enabled.
Declaration
Swift
public static func logCollectionEnabled() -> LogCollectionState
Return Value
The
LogCollectionState
of theCore
log collection. -
Reset the log collection by removing the log files.
Declaration
Swift
public static func resetLogCollection()
-
Enable logs serialization (output logs from either the thread that creates the linphone core or the thread that calls iterate()). Must be called before creating the linphone core.
Declaration
Swift
public static func serializeLogs()
-
Set the max file size in bytes of the files used for log collection. Warning: this function should only not be used to change size dynamically but instead only before calling enableLogCollection(). If you increase max size on runtime, logs chronological order COULD be broken.
Declaration
Swift
public static func setLogCollectionMaxFileSize(size: Int)
Parameters
size
The max file size in bytes of the files used for log collection.
-
Set the path of a directory where the log files will be written for log collection. When log collection is enabled, the function will close the file with the current prefix in the old path and it will open the new file with current prefix in the new path. If you need to change the path and the file at the same time, then you should deactivate log collection with enableLogCollection() before doing modifications.
Declaration
Swift
public static func setLogCollectionPath(path: String)
Parameters
path
The path where the log files will be written.
-
Set the prefix of the filenames that will be used for log collection. When log collection is enabled, the function will close the old file and it will open the new one in the current path. If you need to change the path and the file at the same time, then you should deactivate log collection with enableLogCollection() before doing modifications.
Declaration
Swift
public static func setLogCollectionPrefix(prefix: String)
Parameters
prefix
The prefix to use for the filenames for log collection.
-
True if tunnel support was compiled.
Declaration
Swift
public static func tunnelAvailable() -> Bool
Return Value
true if library was built with tunnel, false otherwise
-
Return the availability of uPnP.
Declaration
Swift
public static func upnpAvailable() -> Bool
Return Value
true if uPnP is available otherwise return false.
-
Tells whether VCARD support is builtin.
Declaration
Swift
public static func vcardSupported() -> Bool
Return Value
true if VCARD is supported, false otherwise.
-
Returns an unmodifiable list of entered accounts.
Declaration
Swift
public var accountList: [Account] { get }
Return Value
-
Returns which adaptive rate algorithm is currently configured for future calls.
See
See also: setAdaptiveRateAlgorithm()Declaration
Swift
public var adaptiveRateAlgorithm: String { get set }
Return Value
the adaptive rate algorithm. Currently two values are supported: ‘advanced’, which is the default value, or ‘basic’.
-
Returns whether adaptive rate control is enabled.
See
See also: enableAdaptiveRateControl()Declaration
Swift
public var adaptiveRateControlEnabled: Bool { get set }
Return Value
true if adaptive rate control is enabled, false otherwise
-
Tells whether the audio adaptive jitter compensation is enabled.
Declaration
Swift
public var audioAdaptiveJittcompEnabled: Bool { get set }
Return Value
true if the audio adaptive jitter compensation is enabled, false otherwise.
-
Returns a list of audio devices, with only the first device for each type To have the list of all audio devices, use getExtendedAudioDevices()
Declaration
Swift
public var audioDevices: [AudioDevice] { get }
Return Value
A list with the first
AudioDevice
of each type -
Get the DSCP field for outgoing audio streams. The DSCP defines the quality of service in IP packets.
Declaration
Swift
public var audioDscp: Int { get set }
Return Value
The current DSCP value
-
Returns the nominal audio jitter buffer size in milliseconds.
Declaration
Swift
public var audioJittcomp: Int { get set }
Return Value
The nominal audio jitter buffer size in milliseconds
-
Use to get multicast address to be used for audio stream.
Declaration
Swift
public var audioMulticastAddr: String { get }
Return Value
an ipv4/6 multicast address or default value.
-
Undocumented
Declaration
Swift
public func setAudiomulticastaddr(newValue: String) throws
-
Use to get multicast state of audio stream.
Declaration
Swift
public var audioMulticastEnabled: Bool { get set }
Return Value
true if subsequent calls will propose multicast ip set by setAudioMulticastAddr()
-
Use to get multicast ttl to be used for audio stream.
Declaration
Swift
public var audioMulticastTtl: Int { get }
Return Value
a time to leave value
-
Undocumented
Declaration
Swift
public func setAudiomulticastttl(newValue: Int) throws
-
Return the list of the available audio payload types.
Declaration
Swift
public var audioPayloadTypes: [PayloadType] { get set }
Return Value
A freshly allocated list of the available payload types. The list must be destroyed with bctbx_list_free() after usage. The elements of the list haven’t to be unref.
-
Gets the UDP port used for audio streaming.
Declaration
Swift
public var audioPort: Int { get set }
Return Value
The UDP port used for audio streaming
-
Gets if the auto download for incoming icalendars is enabled or not.
Declaration
Swift
public var autoDownloadIcalendarsEnabled: Bool { get set }
Return Value
true if icalendars will be automatically downloaded, false otherwise.
-
Gets if the auto download for incoming voice recordings is enabled or not.
Declaration
Swift
public var autoDownloadVoiceRecordingsEnabled: Bool { get set }
Return Value
true if voice recordings will be automatically downloaded, false otherwise.
-
Gets whether auto iterate is enabled or not (Android & iOS only).
Declaration
Swift
public var autoIterateEnabled: Bool { get set }
Return Value
true if iterate() is scheduled automatically, false otherwise
-
Gets if the automatic sending of 180 Ringing is enabled or not.
Declaration
Swift
public var autoSendRingingEnabled: Bool { get set }
Return Value
true if the automatic sending of 180 Ringing is enabled, false otherwise.
-
Returns whether automatic http proxy is enabled.
Declaration
Swift
public var automaticHttpProxyDetectionEnabled: Bool { get set }
Return Value
true if automatic http proxy is enabled or false.
-
Return the avpf report interval in seconds.
Declaration
Swift
public var avpfRrInterval: Int { get set }
Return Value
The current AVPF report interval in seconds
-
Gets the database filename where call logs will be stored.
Declaration
Swift
public var callLogsDatabasePath: String { get set }
Return Value
filesystem path.
-
Special function to check if the callkit is enabled, False by default.
Declaration
Swift
public var callkitEnabled: Bool { get set }
Return Value
true if callkit is enabled, false otherwise.
-
Gets the current list of calls. Note that this list is read-only and might be changed by the core after a function call to iterate(). Similarly the
Call
objects inside it might be destroyed without prior notice. To hold references toCall
object into your program, you must use linphone_call_ref.Declaration
Swift
public var calls: [Call] { get }
Return Value
A list of
Call
-
Get the number of Call.
Declaration
Swift
public var callsNb: Int { get }
Return Value
The current number of calls
-
Get the camera sensor rotation. This is needed on some mobile platforms to get the number of degrees the camera sensor is rotated relative to the screen.
Declaration
Swift
public var cameraSensorRotation: Int { get }
Return Value
The camera sensor rotation in degrees (0 to 360) or -1 if it could not be retrieved
-
Check if the capability negotiation (RFC5939) is supported or not.
Declaration
Swift
public var capabilityNegociationEnabled: Bool { get set }
Return Value
true if capability negotiation is supported; false otherwise.
-
Check if the capability negotiation (RFC5939) reINVITE is enabled or not.
Declaration
Swift
public var capabilityNegotiationReinviteEnabled: Bool { get set }
Return Value
true if capability negotiation reINVITE is enabled; false otherwise.
-
Gets the name of the currently assigned sound device for capture.
Declaration
Swift
public var captureDevice: String { get }
Return Value
The name of the currently assigned sound device for capture.
-
Undocumented
Declaration
Swift
public func setCapturedevice(newValue: String) throws
-
Returns whether chat is enabled.
Declaration
Swift
public var chatEnabled: Bool { get }
Return Value
true if chat is enabled, false otherwise
-
Returns a list of chat rooms.
Declaration
Swift
public var chatRooms: [ChatRoom] { get }
Return Value
List of chat rooms.
-
Get a pointer on the internal conference object.
Declaration
Swift
public var conference: Conference? { get }
Return Value
A pointer on
Conference
or nil if no conference are going on. -
Get the set input volume of the local participant.
Declaration
Swift
public var conferenceLocalInputVolume: Float { get }
Return Value
A value inside [0.0 ; 1.0]
-
Tells whether the conference server feature is enabled.
Declaration
Swift
public var conferenceServerEnabled: Bool { get set }
Return Value
A boolean value telling whether the conference server feature is enabled or not
-
Get the number of participants including me, if it in, in the running conference. The local participant is included in the count only if it is in the conference.
- deprecated: 16/04/2021 Use Conference.getParticipantCount() instead.
Declaration
Swift
@available(*, deprecated) public var conferenceSize: Int { get }
Return Value
The number of participants including me, if it in.
-
Get my consolidated presence.
Declaration
Swift
public var consolidatedPresence: ConsolidatedPresence { get set }
Return Value
My
ConsolidatedPresence
presence -
Gets the current call.
Declaration
Swift
public var currentCall: Call? { get }
Return Value
The current call or nil if no call is running.
-
Get the remote address of the current call.
Declaration
Swift
public var currentCallRemoteAddress: Address? { get }
Return Value
The remote address of the current call or nil if there is no current call.
-
Gets the current LinphoneCoreCbs. This is meant only to be called from a callback to be able to get the user_data associated with the LinphoneCoreCbs that is calling the callback.
Declaration
Swift
public var currentDelegate: CoreDelegate? { get }
Return Value
the LinphoneCoreCbs that has called the last callback
-
Get the effective video definition provided by the camera for the captured video. When preview is disabled or not yet started this function returns a 0x0 video definition.
See
See also: setPreviewVideoDefinition()Declaration
Swift
public var currentPreviewVideoDefinition: VideoDefinition? { get }
Return Value
The captured
VideoDefinition
. -
Returns the default account, that is the one used to determine the current identity.
Declaration
Swift
public var defaultAccount: Account? { get set }
Return Value
The default account.
-
Gets the default lifetime of ephemeral messages in seconds @core core the linphone core.
Declaration
Swift
public var defaultEphemeralLifetime: Int { get set }
Return Value
lifetime of ephemeral messages in seconds
-
Retrieves the first list of
Friend
from the core.Declaration
Swift
public var defaultFriendList: FriendList? { get }
Return Value
the first
FriendList
object or nil. -
Gets the default input audio device.
Declaration
Swift
public var defaultInputAudioDevice: AudioDevice? { get set }
Return Value
The default input audio device
-
Gets the default output audio device.
Declaration
Swift
public var defaultOutputAudioDevice: AudioDevice? { get set }
Return Value
The default output audio device
-
Returns the default proxy configuration, that is the one used to determine the current identity.
Declaration
Swift
public var defaultProxyConfig: ProxyConfig? { get set }
Return Value
The default proxy configuration.
-
Get the name of the default mediastreamer2 filter used for rendering video on the current platform. This is for advanced users of the library, mainly to expose mediastreamer video filter name and status.
Declaration
Swift
public var defaultVideoDisplayFilter: String { get }
Return Value
The default video display filter.
-
Gets the delayed timeout See setDelayedTimeout() for details.
Declaration
Swift
public var delayedTimeout: Int { get set }
Return Value
The current delayed timeout in seconds
-
Gets the current device orientation.
See
See also: setDeviceRotation()Declaration
Swift
public var deviceRotation: Int { get set }
Return Value
The current device orientation
-
Get the current digest authentication policy applicable for SIP and HTTP. Get the current digest authentication policy applicable for SIP and HTTP.
Declaration
Swift
public var digestAuthenticationPolicy: DigestAuthenticationPolicy? { get set }
Return Value
The current digest authentication policy.
-
Get whether the microphone will be completely deactivated when muted. Please refer to setDisableRecordOnMute().
Declaration
Swift
public var disableRecordOnMute: Bool { get set }
Return Value
True if you wish to entirely stop the audio recording when muting the microphone.
-
Tells whether DNS search (use of local domain if the fully qualified name did return results) is enabled.
Declaration
Swift
public var dnsSearchEnabled: Bool { get set }
Return Value
true if DNS search is enabled, false if disabled.
-
Forces liblinphone to use the supplied list of dns servers, instead of system’s ones.
Declaration
Swift
public var dnsServers: [String] { get set }
Parameters
servers
A list of strings containing the IP addresses of DNS servers to be used. Setting to nil restores default behaviour, which is to use the DNS server list provided by the system. The list is copied internally.
-
Forces liblinphone to use the supplied list of dns servers, instead of system’s ones and set dns_set_by_app at true or false according to value of servers list.
Declaration
Swift
public var dnsServersApp: [String] { get set }
Parameters
servers
A list of strings containing the IP addresses of DNS servers to be used. Setting to nil restores default behaviour, which is to use the DNS server list provided by the system. The list is copied internally.
-
Tells if the DNS was set by an application.
Declaration
Swift
public var dnsSetByApp: Bool { get }
Return Value
true if DNS was set by app, false otherwise.
-
Tells whether DNS SRV resolution is enabled.
Declaration
Swift
public var dnsSrvEnabled: Bool { get set }
Return Value
true if DNS SRV resolution is enabled, false if disabled.
-
Retrieve the maximum available download bandwidth. This value was set by setDownloadBandwidth().
Declaration
Swift
public var downloadBandwidth: Int { get set }
Return Value
the download bandiwdth in kbits/s, 0 for infinite
-
Get audio packetization time linphone expects to receive from peer. A value of zero means that ptime is not specified.
Declaration
Swift
public var downloadPtime: Int { get set }
Return Value
the download packetization time set
-
Returns true if echo cancellation is enabled.
Declaration
Swift
public var echoCancellationEnabled: Bool { get set }
Return Value
A boolean value telling whether echo cancellation is enabled or disabled
-
Get the name of the mediastreamer2 filter used for echo cancelling.
Declaration
Swift
public var echoCancellerFilterName: String { get set }
Return Value
The name of the mediastreamer2 filter used for echo cancelling.
-
Tells whether echo limiter is enabled.
Declaration
Swift
public var echoLimiterEnabled: Bool { get set }
Return Value
true if the echo limiter is enabled, false otherwise.
-
Enable or disable the UPDATE method support.
Declaration
Swift
public var enableSipUpdate: Int { get set }
Parameters
value
Enable or disable it
-
Sets expected available upload bandwidth This is IP bandwidth, in kbit/s. This information is used by liblinphone together with remote side available bandwidth signaled in SDP messages to properly configure audio & video codec’s output bitrate.
Declaration
Swift
public var expectedBandwidth: Int { get set }
Parameters
bandwidth
the bandwidth in kbits/s, 0 for infinite
-
Returns the list of all audio devices.
Declaration
Swift
public var extendedAudioDevices: [AudioDevice] { get }
Return Value
A list of all
AudioDevice
-
Get the globaly set http file transfer server to be used for content type application/vnd.gsma.rcs-ft-http+xml. Url may be like: “https://file.linphone.org/upload.php”.
Declaration
Swift
public var fileTransferServer: String { get set }
Return Value
URL of the file server.
-
Indicates whether the ICE relay path is forcibly selected.
See
See also: enableForcedIceRelay().Declaration
Swift
public var forcedIceRelayEnabled: Bool { get set }
Return Value
a boolean value indicating whether forced relay is enabled.
-
Returns whether or not friend lists subscription are enabled.
Declaration
Swift
public var friendListSubscriptionEnabled: Bool { get set }
Return Value
whether or not the feature is enabled
-
Gets the database filename where friends will be stored.
Declaration
Swift
public var friendsDatabasePath: String { get set }
Return Value
filesystem path.
-
Retrieves the list of
FriendList
from the core.Declaration
Swift
public var friendsLists: [FriendList] { get }
Return Value
A list of
FriendList
. -
Returns enablement of RFC3389 generic comfort noise algorithm.
Declaration
Swift
public var genericComfortNoiseEnabled: Bool { get set }
Return Value
true if generic comfort noise is enabled, false otherwise.
-
Returns the global state of core.
Declaration
Swift
public var globalState: GlobalState { get }
Return Value
a
GlobalState
enum. -
Returns true if hostname part of primary contact is guessed automatically.
Declaration
Swift
public var guessHostname: Bool { get set }
Return Value
true if guess hostname enabled, false otherwise.
-
Get http proxy address to be used for signaling.
Declaration
Swift
public var httpProxyHost: String { get set }
Return Value
hostname of IP adress of the http proxy (can be nil to disable).
-
Get http proxy port to be used for signaling.
Declaration
Swift
public var httpProxyPort: Int { get set }
Return Value
port of the http proxy.
-
Gets the default identity SIP address. This is an helper function. If no default proxy is set, this will return the primary contact ( see getPrimaryContact() ). If a default proxy is set it returns the registered identity on the proxy.
Declaration
Swift
public var identity: String { get }
Return Value
The default identity SIP address.
-
Get the
ImNotifPolicy
object controlling the instant messaging notifications.Declaration
Swift
public var imNotifPolicy: ImNotifPolicy? { get }
Return Value
A
ImNotifPolicy
object. -
Gets the in call timeout See setInCallTimeout() for details.
Declaration
Swift
public var inCallTimeout: Int { get set }
Return Value
The current in call timeout in seconds
-
Returns the incoming call timeout See setIncTimeout() for details.
Declaration
Swift
public var incTimeout: Int { get set }
Return Value
The current incoming call timeout in seconds
-
Gets the input audio device for the current call.
Declaration
Swift
public var inputAudioDevice: AudioDevice? { get set }
Return Value
The input audio device for the current or first call, nil if there is no call.
-
Tells whether IPv6 is enabled or not.
See
See also: enableIpv6() for more details on how IPv6 is supported in liblinphone.Declaration
Swift
public var ipv6Enabled: Bool { get set }
Return Value
A boolean value telling whether IPv6 is enabled or not
-
Gets if the auto download for incoming icalendars is enabled or not.
- deprecated: 16/12/2021 Use autoDownloadIcalendarsEnabled() instead.
Declaration
Swift
@available(*, deprecated) public var isAutoDownloadIcalendarsEnabled: Bool { get }
Return Value
true if icalendars will be automatically downloaded, false otherwise.
-
Gets if the auto download for incoming voice recordings is enabled or not.
- deprecated: 16/12/2021 Use autoDownloadVoiceRecordingsEnabled() instead.
Declaration
Swift
@available(*, deprecated) public var isAutoDownloadVoiceRecordingsEnabled: Bool { get }
Return Value
true if voice recordings will be automatically downloaded, false otherwise.
-
Gets whether auto iterate is enabled or not (Android & iOS only).
- deprecated: 16/12/2021 Use autoIterateEnabled() instead.
Declaration
Swift
@available(*, deprecated) public var isAutoIterateEnabled: Bool { get }
Return Value
true if iterate() is scheduled automatically, false otherwise
-
Check if the capability negotiation (RFC5939) reINVITE is enabled or not.
- deprecated: 16/12/2021 Use capabilityNegotiationReinviteEnabled() instead.
Declaration
Swift
@available(*, deprecated) public var isCapabilityNegotiationReinviteEnabled: Bool { get }
Return Value
true if capability negotiation reINVITE is enabled; false otherwise.
-
Check whether the device is echo canceller calibration is required.
Declaration
Swift
public var isEchoCancellerCalibrationRequired: Bool { get }
Return Value
true if it is required, false otherwise
-
Returns whether or not friend lists subscription are enabled.
- deprecated: 16/12/2021 Use friendListSubscriptionEnabled() instead.
Declaration
Swift
@available(*, deprecated) public var isFriendListSubscriptionEnabled: Bool { get }
Return Value
whether or not the feature is enabled
-
Gets whether the Core is considering itself in background or not. The Core foreground/background state depends on the last call made to enterBackground() or enterForeground(). - Returns: true if the Core is in background, false otherwise.
Declaration
Swift
public var isInBackground: Bool { get }
-
Indicates whether the local participant is part of a conference.
Warning
That function automatically fails in the case of conferences using a conferencet server (focus). If you use such a conference, you should use Conference.removeParticipant() instead.- deprecated: 09/03/2021 Use Conference.isIn() instead.
Declaration
Swift
@available(*, deprecated) public var isInConference: Bool { get }
Return Value
true if the local participant is in a conference, false otherwise.
-
Tells whether there is an incoming invite pending.
Declaration
Swift
public var isIncomingInvitePending: Bool { get }
Return Value
A boolean telling whether an incoming invite is pending or not.
-
Check if the configured media encryption is mandatory or not.
Declaration
Swift
public var isMediaEncryptionMandatory: Bool { get }
Return Value
true if media encryption is mandatory; false otherwise.
-
Returns whether the native ringing is enabled or not.
- deprecated: 16/12/2021 Use nativeRingingEnabled() instead.
Declaration
Swift
@available(*, deprecated) public var isNativeRingingEnabled: Bool { get }
Return Value
True if we use the native ringing, false otherwise
-
return network state either as positioned by the application or by linphone itself.
Declaration
Swift
public var isNetworkReachable: Bool { get }
Return Value
true if network is reachable, false otherwise
-
Gets whether push notifications are available or not (Android & iOS only).
Declaration
Swift
public var isPushNotificationAvailable: Bool { get }
Return Value
true if push notifications are available, false otherwise
-
Gets whether push notifications are enabled or not (Android & iOS only). If not, the app will have to handle all the push-related settings for each accounts
- deprecated: 16/12/2021 Use pushNotificationEnabled() instead.
Declaration
Swift
@available(*, deprecated) public var isPushNotificationEnabled: Bool { get }
Return Value
true if push notifications are enabled, false otherwise
-
Gets if the record aware feature is enabled or not.
- deprecated: 16/12/2021 Use recordAwareEnabled() instead.
Declaration
Swift
@available(*, deprecated) public var isRecordAwareEnabled: Bool { get }
Return Value
true if the record aware feature is enabled, false otherwise.
-
Returns whether or not sender name is hidden in forward message.
Declaration
Swift
public var isSenderNameHiddenInForwardMessage: Bool { get }
Return Value
whether or not the feature
-
Get whether the tls server certificate must be verified when connecting to a SIP/TLS server.
Declaration
Swift
public var isVerifyServerCertificates: Bool { get }
Return Value
True if the tls server certificate must be verified
-
Get whether the tls server certificate common name must be verified when connecting to a SIP/TLS server.
Declaration
Swift
public var isVerifyServerCn: Bool { get }
Return Value
True if the tls server certificate common name must be verified
-
Gets whether the device will vibrate while an incoming call is ringing (Android only).
- deprecated: 16/12/2021 Use vibrationOnIncomingCallEnabled() instead.
Declaration
Swift
@available(*, deprecated) public var isVibrationOnIncomingCallEnabled: Bool { get }
Return Value
true if the device will vibrate (if possible), false otherwise
-
Check if RTP port is set to 0 when a stream is inactive.
- deprecated: 16/12/2021 Use zeroRtpPortForStreamInactiveEnabled() instead.
Declaration
Swift
@available(*, deprecated) public var isZeroRtpPortForStreamInactiveEnabled: Bool { get }
Return Value
true if the RTP port is set to 0 if the stream direction is inactive; false otherwise.
-
Is signaling keep alive enabled.
Declaration
Swift
public var keepAliveEnabled: Bool { get set }
Return Value
A boolean value telling whether signaling keep alive is enabled
-
Get the latest outgoing call log.
Declaration
Swift
public var lastOutgoingCallLog: CallLog? { get }
Return Value
The last outgoing call log if any.
-
Returns a list of entered LDAPs. Items must be freed with linphone_ldap_unref
Declaration
Swift
public var ldapList: [Ldap] { get }
Return Value
-
Tells wether LIME X3DH is enabled or not.
Declaration
Swift
public var limeX3DhEnabled: Bool { get set }
Return Value
The current lime state
-
Get the x3dh server url.
Declaration
Swift
public var limeX3DhServerUrl: String { get set }
Return Value
The x3dh server url.
-
Get the list of linphone specs string values representing what functionalities the linphone client supports.
Declaration
Swift
public var linphoneSpecsList: [String] { get set }
Return Value
A list of supported specs. The list must be freed with bctbx_list_free() after usage.
-
Special function to check if the local network permission has been granted by the user (useful for iOS). The test performed by this function may popup the local network permission dialog, for that reason it could be a good idea to check it twice to conclude that the user has deny the permission.
Declaration
Swift
public var localPermissionEnabled: Bool { get }
Return Value
true if local permission request is granted, false otherwise.
-
Gets the url of the server where to upload the collected log files.
Declaration
Swift
public var logCollectionUploadServerUrl: String { get set }
Return Value
The url of the server where to upload the collected log files.
-
Get the maximum number of simultaneous calls Linphone core can manage at a time. All new call above this limit are declined with a busy answer
Declaration
Swift
public var maxCalls: Int { get set }
Return Value
max number of simultaneous calls
-
Gets the size under which incoming files in chat messages will be downloaded automatically.
Declaration
Swift
public var maxSizeForAutoDownloadIncomingFiles: Int { get set }
Return Value
The size in bytes, -1 if autodownload feature is disabled, 0 to download them all no matter the size
-
Gets the name of the currently assigned sound device for media.
Declaration
Swift
public var mediaDevice: String { get }
Return Value
The name of the currently assigned sound device for capture.
-
Undocumented
Declaration
Swift
public func setMediadevice(newValue: String) throws
-
Get the media encryption policy being used for RTP packets.
Declaration
Swift
public var mediaEncryption: MediaEncryption { get }
Return Value
The
MediaEncryption
policy being used. -
Undocumented
Declaration
Swift
public func setMediaencryption(newValue: MediaEncryption) throws
-
Define whether the configured media encryption is mandatory, if it is and the negotation cannot result in the desired media encryption then the call will fail. If not an INVITE will be resent with encryption disabled.
Declaration
Swift
public var mediaEncryptionMandatory: Bool? { get set }
Parameters
mandatory
true to set it mandatory; false otherwise.
-
This method is called by the application to notify the linphone core library when the media (RTP) network is reachable. This is for advanced usage, when SIP and RTP layers are required to use different interfaces. Most applications just need setNetworkReachable().
Declaration
Swift
public var mediaNetworkReachable: Bool? { get set }
Parameters
reachable
true if network is reachable, false otherwise
-
This function returns the media resource mode for this core.
Declaration
Swift
public var mediaResourceMode: MediaResourceMode { get set }
Return Value
The media resource mode
-
Tells whether the microphone is enabled.
Declaration
Swift
public var micEnabled: Bool { get set }
Return Value
true if the microphone is enabled, false if disabled.
-
Get microphone gain in db.
Declaration
Swift
public var micGainDb: Float { get set }
Return Value
The current microphone gain
-
Get the number of missed calls. Once checked, this counter can be reset with resetMissedCallsCount().
Declaration
Swift
public var missedCallsCount: Int { get }
Return Value
The number of missed calls.
-
Returns the maximum transmission unit size in bytes.
Declaration
Swift
public var mtu: Int { get set }
-
Get the public IP address of NAT being used.
Declaration
Swift
public var natAddress: String { get set }
Return Value
The public IP address of NAT being used.
-
Get the native window handle of the video preview window. see setNativeVideoWindowId() for details about window_id There is a special case for Qt : getNativePreviewWindowId() wreturns a
QQuickFramebufferObject::Renderer and creates one if it doesn’t exist. This
object must be returned by your QQuickFramebufferObject::createRenderer() overload for Qt. Note : Qt blocks GUI thread when calling createRenderer(), so it is safe to call linphone functions there if needed.
Declaration
Swift
public var nativePreviewWindowId: UnsafeMutableRawPointer? { get set }
Return Value
The native window handle of the video preview window.
-
Returns whether the native ringing is enabled or not.
Declaration
Swift
public var nativeRingingEnabled: Bool { get set }
Return Value
True if we use the native ringing, false otherwise
-
Get the native window handle of the video window. see linphone_core_set_native_video_window_id for details about window_id There is a special case for Qt : getNativeVideoWindowId() returns a
QQuickFramebufferObject::Renderer and creates one if it doesn’t exist. This
object must be returned by your QQuickFramebufferObject::createRenderer() overload for Qt. Note : Qt blocks GUI thread when calling createRenderer(), so it is safe to call linphone functions there if needed.
Declaration
Swift
public var nativeVideoWindowId: UnsafeMutableRawPointer? { get set }
Return Value
The native window handle of the video window.
-
This method is called by the application to notify the linphone core library when network is reachable. Calling this method with true trigger linphone to initiate a registration process for all proxies. Calling this method disables the automatic network detection mode. It means you must call this method after each network state changes.
Declaration
Swift
public var networkReachable: Bool? { get set }
Parameters
reachable
true if network is reachable, false otherwise
-
Gets the value of the no-rtp timeout. When no RTP or RTCP packets have been received for a while
Core
will consider the call is broken (remote end crashed or disconnected from the network), and thus will terminate the call. The no-rtp timeout is the duration above which the call is considered broken.Declaration
Swift
public var nortpTimeout: Int { get set }
Return Value
The value of the no-rtp timeout in seconds
-
Gets the output audio device for the current call.
Declaration
Swift
public var outputAudioDevice: AudioDevice? { get set }
Return Value
The output audio device for the current or first call, nil if there is no call.
-
Get the wav file that is played when putting somebody on hold, or when files are used instead of soundcards (see setUseFiles()). The file is a 16 bit linear wav file.
Declaration
Swift
public var playFile: String { get set }
Return Value
The path to the file that is played when putting somebody on hold.
-
Gets the name of the currently assigned sound device for playback.
Declaration
Swift
public var playbackDevice: String { get }
Return Value
The name of the currently assigned sound device for playback.
-
Undocumented
Declaration
Swift
public func setPlaybackdevice(newValue: String) throws
-
Get playback gain in db before entering sound card.
Declaration
Swift
public var playbackGainDb: Float { get set }
Return Value
The current playback gain
-
Returns the preferred video framerate, previously set by setPreferredFramerate().
Declaration
Swift
public var preferredFramerate: Float { get set }
Return Value
frame rate in number of frames per seconds.
-
Get the preferred video definition for the stream that is captured and sent to the remote party.
Declaration
Swift
public var preferredVideoDefinition: VideoDefinition? { get set }
Return Value
The preferred
VideoDefinition
-
Sets the preferred video definition by its name. Call Factory.getSupportedVideoDefinitions() to have a list of supported video definitions.
Declaration
Swift
public var preferredVideoDefinitionByName: String { get set }
Parameters
name
The name of the definition to set
-
Get my presence model.
Declaration
Swift
public var presenceModel: PresenceModel? { get set }
Return Value
A
PresenceModel
object, or nil if no presence model has been set. -
Get the definition of the captured video.
See
See also: setPreviewVideoDefinition()Declaration
Swift
public var previewVideoDefinition: VideoDefinition? { get set }
Return Value
The captured
VideoDefinition
if it was previously set by setPreviewVideoDefinition(), otherwise a 0x0 LinphoneVideoDefinition. -
Declaration
Swift
public var previewVideoDefinitionByName: String { get set }
Parameters
name
The name of the definition to set
-
Returns the default identity when no proxy configuration is used.
Declaration
Swift
public var primaryContact: String { get }
Return Value
the primary contact identity
-
Undocumented
Declaration
Swift
public func setPrimarycontact(newValue: String) throws
-
Get provisioning URI.
Declaration
Swift
public var provisioningUri: String { get }
Return Value
the provisioning URI.
-
Undocumented
Declaration
Swift
public func setProvisioninguri(newValue: String) throws
-
Returns an unmodifiable list of entered proxy configurations.
Declaration
Swift
public var proxyConfigList: [ProxyConfig] { get }
Return Value
A list of
ProxyConfig
. -
Returns the push incoming call timeout See setPushIncomingCallTimeout() for details.
Declaration
Swift
public var pushIncomingCallTimeout: Int { get set }
Return Value
The current push incoming call timeout in seconds
-
Gets whether push notifications are enabled or not (Android & iOS only). If not, the app will have to handle all the push-related settings for each accounts
Declaration
Swift
public var pushNotificationEnabled: Bool { get set }
Return Value
true if push notifications are enabled, false otherwise
-
Tells whether QRCode is enabled in the preview.
Declaration
Swift
public var qrcodeVideoPreviewEnabled: Bool { get set }
Return Value
A boolean value telling whether QRCode is enabled in the preview.
-
Gets if realtime text is enabled or not.
Declaration
Swift
public var realtimeTextEnabled: Bool { get }
Return Value
true if realtime text is enabled, false otherwise
-
Gets if the record aware feature is enabled or not.
Declaration
Swift
public var recordAwareEnabled: Bool { get set }
Return Value
true if the record aware feature is enabled, false otherwise.
-
Get the wav file where incoming stream is recorded, when files are used instead of soundcards (see setUseFiles()). This feature is different from call recording (CallParams.setRecordFile()) The file is a 16 bit linear wav file.
Declaration
Swift
public var recordFile: String { get set }
Return Value
The path to the file where incoming stream is recorded.
-
Get the ring back tone played to far end during incoming calls.
Declaration
Swift
public var remoteRingbackTone: String { get set }
Return Value
the path to the remote ring back tone to be played.
-
Tells whether NACK context is enabled or not.
Declaration
Swift
public var retransmissionOnNackEnabled: Bool { get set }
Return Value
A boolean value telling whether NACK context is enabled or not
-
Returns the path to the wav file used for ringing.
Declaration
Swift
public var ring: String { get set }
Return Value
The path to the wav file used for ringing.
-
Tells whether the ring play is enabled during an incoming early media call.
Declaration
Swift
public var ringDuringIncomingEarlyMedia: Bool { get set }
-
Returns the path to the wav file used for ringing back.
Declaration
Swift
public var ringback: String { get set }
Return Value
The path to the wav file used for ringing back.
-
Gets the name of the currently assigned sound device for ringing.
Declaration
Swift
public var ringerDevice: String { get }
Return Value
The name of the currently assigned sound device for ringing.
-
Undocumented
Declaration
Swift
public func setRingerdevice(newValue: String) throws
-
Gets the path to a file or folder containing the trusted root CAs (PEM format)
Declaration
Swift
public var rootCa: String { get set }
Return Value
The path to a file or folder containing the trusted root CAs.
-
Sets the trusted root CAs (PEM format)
Declaration
Swift
public var rootCaData: String { get set }
Parameters
data
The trusted root CAs as a string
-
Returns whether RTP bundle mode (also known as Media Multiplexing) is enabled. See https://tools.ietf.org/html/draft-ietf-mmusic-sdp-bundle-negotiation-54 for more information.
Declaration
Swift
public var rtpBundleEnabled: Bool { get set }
Return Value
a boolean indicating the enablement of rtp bundle mode.
-
Media offer control param for SIP INVITE.
Declaration
Swift
public var sdp200AckEnabled: Bool { get set }
Return Value
true if INVITE has to be sent whitout SDP.
-
Tells whether video self view during call is enabled or not.
See
See also: enableSelfView() for details.Declaration
Swift
public var selfViewEnabled: Bool { get set }
Return Value
A boolean value telling whether self view is enabled
-
Enable whether or not to hide sender name in forward message.
Declaration
Swift
public var senderNameHiddenInForwardMessageEnabled: Bool? { get set }
Parameters
enable
whether or not to enable the feature
-
Check if the Session Timers feature is enabled.
Declaration
Swift
public var sessionExpiresEnabled: Bool { get set }
-
Returns the session expires min value, 90 by default.
Declaration
Swift
public var sessionExpiresMinValue: Int { get set }
-
Returns the session expires refresher value.
Declaration
Swift
public var sessionExpiresRefresherValue: SessionExpiresRefresher { get set }
-
Returns the session expires value.
Declaration
Swift
public var sessionExpiresValue: Int { get set }
-
Get the DSCP field for SIP signaling channel. The DSCP defines the quality of service in IP packets.
Declaration
Swift
public var sipDscp: Int { get set }
Return Value
The current DSCP value
-
This method is called by the application to notify the linphone core library when the SIP network is reachable. This is for advanced usage, when SIP and RTP layers are required to use different interfaces. Most applications just need setNetworkReachable().
Declaration
Swift
public var sipNetworkReachable: Bool? { get set }
Parameters
reachable
true if network is reachable, false otherwise
-
Get the SIP transport timeout.
Declaration
Swift
public var sipTransportTimeout: Int { get set }
Return Value
The SIP transport timeout in milliseconds.
-
Gets the list of the available sound devices.
- deprecated: 10/04/2021 Use getAudioDevices() instead.
Declaration
Swift
@available(*, deprecated) public var soundDevicesList: [String] { get }
Return Value
An unmodifiable array of strings contanining the names of the available sound devices that is nil terminated.
-
Get the crypto suites available to the core.
Declaration
Swift
public var srtpCryptoSuites: String { get set }
Return Value
a comma separated list of supported suites
-
Get the path to the image file streamed when “Static picture” is set as the video device.
Declaration
Swift
public var staticPicture: String { get }
Return Value
The path to the image file streamed when “Static picture” is set as the video device.
-
Undocumented
Declaration
Swift
public func setStaticpicture(newValue: String) throws
-
Get the frame rate for static picture.
Declaration
Swift
public var staticPictureFps: Float { get }
Return Value
The frame rate used for static picture.
-
Undocumented
Declaration
Swift
public func setStaticpicturefps(newValue: Float) throws
-
Get the STUN server address being used.
Declaration
Swift
public var stunServer: String { get set }
Return Value
The STUN server address being used.
-
Returns a null terminated table of strings containing the file format extension supported for call recording.
Declaration
Swift
public var supportedFileFormatsList: [String] { get }
Return Value
The supported formats, typically ‘wav’ and ‘mkv’.
-
Set the supported tags.
Declaration
Swift
public var supportedTag: String { get set }
-
Get the support level of the 100rel attribute.
Declaration
Swift
public var tag100RelSupportLevel: SupportLevel { get set }
Return Value
The 100 rel support level
-
Define whether tcap lines are going to be merged if capability negotiation (RFC5939) is supported.
Declaration
Swift
public var tcapLineMergingEnabled: Bool? { get set }
Parameters
merge
true to merge tcap lines with consecutive indexes; false otherwise.
-
Check if tcap lines are going to the merged if the capability negotiation (RFC5939) is supported or not.
Declaration
Swift
public var tcapLinesMergingEnabled: Bool { get }
Return Value
true if tcap lines with consecutive indexes are going to be merged; false otherwise.
-
Return the list of the available text payload types.
Declaration
Swift
public var textPayloadTypes: [PayloadType] { get set }
Return Value
A freshly allocated list of the available payload types. The list must be destroyed with bctbx_list_free() after usage. The elements of the list haven’t to be unref.
-
Gets the UDP port used for text streaming.
Declaration
Swift
public var textPort: Int { get set }
Return Value
The UDP port used for text streaming
-
Gets the TLS certificate.
Declaration
Swift
public var tlsCert: String { get set }
Return Value
the TLS certificate or nil if not set yet.
-
Gets the path to the TLS certificate file.
Declaration
Swift
public var tlsCertPath: String { get set }
Return Value
the TLS certificate path or nil if not set yet.
-
Gets the TLS key.
Declaration
Swift
public var tlsKey: String { get set }
Return Value
the TLS key or nil if not set yet.
-
Gets the path to the TLS key file.
Declaration
Swift
public var tlsKeyPath: String { get set }
Return Value
the TLS key path or nil if not set yet.
-
Retrieves the port configuration used for each transport (udp, tcp, tls). A zero value port for a given transport means the transport is not used. A value of LC_SIP_TRANSPORT_RANDOM (-1) means the port is to be chosen randomly by the system. A value of LC_SIP_TRANSPORT_DONTBIND (-2) means that the socket will not be bound explicitely, in other words liblinphone won’t listen for incoming connections at all. This mode is suitable for a pure client application (ex: a mobile application).
Declaration
Swift
public var transports: Transports? { get }
Return Value
A
Transports
structure with the configured ports -
Undocumented
Declaration
Swift
public func setTransports(newValue: Transports) throws
-
Retrieves the real port number assigned for each sip transport (udp, tcp, tls). A zero value means that the transport is not activated. If LC_SIP_TRANSPORT_RANDOM was passed to linphone_core_set_sip_transports, the random port choosed by the system is returned.
Declaration
Swift
public var transportsUsed: Transports? { get }
Return Value
A
Transports
structure with the ports being used -
Return the global unread chat message count.
Declaration
Swift
public var unreadChatMessageCount: Int { get }
Return Value
The global unread chat message count.
-
Return the unread chat message count for all active local address. (Primary contact + proxy configs.)
Declaration
Swift
public var unreadChatMessageCountFromActiveLocals: Int { get }
Return Value
The unread chat message count.
-
Retrieve the maximum available upload bandwidth. This value was set by setUploadBandwidth().
Declaration
Swift
public var uploadBandwidth: Int { get set }
Return Value
the upload bandiwdth in kbits/s, 0 for infinite
-
Set audio packetization time linphone will send (in absence of requirement from peer) A value of 0 stands for the current codec default packetization time.
Declaration
Swift
public var uploadPtime: Int { get set }
Return Value
the upload packetization time set
-
Return the external ip address of router. In some cases the uPnP can have an external ip address but not a usable uPnP (state different of Ok).
Declaration
Swift
public var upnpExternalIpaddress: String { get }
Return Value
a null terminated string containing the external ip address. If the the external ip address is not available return null.
-
Return the internal state of uPnP.
Declaration
Swift
public var upnpState: UpnpState { get }
Return Value
an LinphoneUpnpState.
-
Gets whether linphone is currently streaming audio from and to files, rather than using the soundcard.
Declaration
Swift
public var useFiles: Bool { get set }
Return Value
A boolean value representing whether linphone is streaming audio from and to files or not.
-
Indicates whether SIP INFO is used to send digits.
Declaration
Swift
public var useInfoForDtmf: Bool { get set }
Return Value
A boolean value telling whether SIP INFO is used to send digits
-
Indicates whether RFC2833 is used to send digits.
Declaration
Swift
public var useRfc2833ForDtmf: Bool { get set }
Return Value
A boolean value telling whether RFC2833 is used to send digits
-
Gets the user-agent as a string.
Declaration
Swift
public var userAgent: String { get }
Return Value
liblinphone’s user agent as a string.
-
Get the path to the directory storing the user’s certificates.
Declaration
Swift
public var userCertificatesPath: String { get set }
Return Value
The path to the directory storing the user’s certificates.
-
Retrieves the user pointer that was given to linphone_core_new
Declaration
Swift
public var userData: UnsafeMutableRawPointer? { get set }
Return Value
The user data associated with the
Core
object. -
Gets whether the device will vibrate while an incoming call is ringing (Android only).
Declaration
Swift
public var vibrationOnIncomingCallEnabled: Bool { get set }
Return Value
true if the device will vibrate (if possible), false otherwise
-
Get the default policy for video. See setVideoActivationPolicy() for more details.
Declaration
Swift
public var videoActivationPolicy: VideoActivationPolicy? { get set }
Return Value
The video policy being used
-
Tells whether the video adaptive jitter compensation is enabled.
Declaration
Swift
public var videoAdaptiveJittcompEnabled: Bool { get set }
Return Value
true if the video adaptive jitter compensation is enabled, false otherwise.
-
Tells whether video capture is enabled.
Declaration
Swift
public var videoCaptureEnabled: Bool { get set }
Return Value
true if video capture is enabled, false if disabled.
-
Returns the name of the currently active video device.
Declaration
Swift
public var videoDevice: String { get }
Return Value
The name of the currently active video device.
-
Undocumented
Declaration
Swift
public func setVideodevice(newValue: String) throws
-
Gets the list of the available video capture devices.
Declaration
Swift
public var videoDevicesList: [String] { get }
Return Value
An unmodifiable array of strings contanining the names of the available video capture devices that is nil terminated.
-
Tells whether video display is enabled.
Declaration
Swift
public var videoDisplayEnabled: Bool { get set }
Return Value
true if video display is enabled, false if disabled.
-
Get the name of the mediastreamer2 filter used for rendering video.
Declaration
Swift
public var videoDisplayFilter: String { get set }
Return Value
The currently selected video display filter.
-
Get the DSCP field for outgoing video streams. The DSCP defines the quality of service in IP packets.
Declaration
Swift
public var videoDscp: Int { get set }
Return Value
The current DSCP value
-
Returns true if either capture or display is enabled, false otherwise. same as ( videoCaptureEnabled() | videoDisplayEnabled() )
Declaration
Swift
public var videoEnabled: Bool { get }
Return Value
true if either capture or display is enabled, false otherwise.
-
Returns the nominal video jitter buffer size in milliseconds.
Declaration
Swift
public var videoJittcomp: Int { get set }
Return Value
The nominal video jitter buffer size in milliseconds
-
Use to get multicast address to be used for video stream.
Declaration
Swift
public var videoMulticastAddr: String { get }
Return Value
an ipv4/6 multicast address, or default value.
-
Undocumented
Declaration
Swift
public func setVideomulticastaddr(newValue: String) throws
-
Use to get multicast state of video stream.
Declaration
Swift
public var videoMulticastEnabled: Bool { get set }
Return Value
true if subsequent calls will propose multicast ip set by setVideoMulticastAddr()
-
Use to get multicast ttl to be used for video stream.
Declaration
Swift
public var videoMulticastTtl: Int { get }
Return Value
a time to leave value
-
Undocumented
Declaration
Swift
public func setVideomulticastttl(newValue: Int) throws
-
Return the list of the available video payload types.
Declaration
Swift
public var videoPayloadTypes: [PayloadType] { get set }
Return Value
A freshly allocated list of the available payload types. The list must be destroyed with bctbx_list_free() after usage. The elements of the list haven’t to be unref.
-
Gets the UDP port used for video streaming.
Declaration
Swift
public var videoPort: Int { get set }
Return Value
The UDP port used for video streaming
-
Get the video preset used for video calls.
Declaration
Swift
public var videoPreset: String { get set }
Return Value
The name of the video preset used for video calls (can be nil if the default video preset is used).
-
Tells whether video preview is enabled.
Declaration
Swift
public var videoPreviewEnabled: Bool { get set }
Return Value
A boolean value telling whether video preview is enabled
-
Enable or disable video source reuse when switching from preview to actual video call. This source reuse is useful when you always display the preview, even before calls are initiated. By keeping the video source for the transition to a real video call, you will smooth out the source close/reopen cycle. This function does not have any effect durfing calls. It just indicates the
Core
to initiate future calls with video source reuse or not. Also, at the end of a video call, the source will be closed whatsoever for now.Declaration
Swift
public var videoSourceReuseEnabled: Bool? { get set }
Parameters
enable
true to enable video source reuse. false to disable it for subsequent calls.
-
Tells whether Wifi only mode is enabled or not.
Warning
Only works for Android platform.Declaration
Swift
public var wifiOnlyEnabled: Bool { get set }
Return Value
A boolean value telling whether Wifi only mode is enabled or not
-
Check if RTP port is set to 0 when a stream is inactive.
Declaration
Swift
public var zeroRtpPortForStreamInactiveEnabled: Bool { get set }
Return Value
true if the RTP port is set to 0 if the stream direction is inactive; false otherwise.
-
Get the path to the file storing the zrtp secrets cache.
Declaration
Swift
public var zrtpSecretsFile: String { get set }
Return Value
The path to the file storing the zrtp secrets cache.
-
Special function to indicate if the audio session is activated. Must be called when ProviderDelegate of the callkit notifies that the audio session is activated or deactivated.
Declaration
Swift
public func activateAudioSession(actived: Bool)
-
Add all current calls into the conference. If no conference is running a new internal conference context is created and all current calls are added to it.
Warning
This function guarantees that the local endpoint is added to the conference.Declaration
Swift
public func addAllToConference() throws
Return Value
0 if succeeded. Negative number if failed
-
Add support for the specified content type. It is the application responsibility to handle it correctly afterwards.
Declaration
Swift
public func addContentTypeSupport(contentType: String)
Parameters
contentType
The content type to add support for
-
Add a friend list.
Declaration
Swift
public func addFriendList(list: FriendList)
Parameters
list
FriendList
object -
Add or update a LDAP server and save it to the configuration.
Declaration
Swift
public func addLdap(ldap: Ldap)
Parameters
ldap
The LDAP to add/update.
-
Add the given linphone specs to the list of functionalities the linphone client supports.
Declaration
Swift
public func addLinphoneSpec(spec: String)
Parameters
spec
The spec to add
-
Add a proxy configuration. This will start registration on the proxy, if registration is enabled.
Declaration
Swift
public func addProxyConfig(config: ProxyConfig) throws
Parameters
config
the
ProxyConfig
to addReturn Value
0 if successful, -1 otherwise
-
This function controls signaling features supported by the core. They are typically included in a SIP Supported header.
Declaration
Swift
public func addSupportedTag(tag: String)
Parameters
tag
The feature tag name
-
Add a participant to the conference. If no conference is going on a new internal conference context is created and the participant is added to it.
Declaration
Swift
public func addToConference(call: Call) throws
Parameters
call
The current call with the participant to add
Return Value
0 if succeeded. Negative number if failed
-
Special function to indicate if the audio route is changed. Must be called in the callback of AVAudioSessionRouteChangeNotification.
- deprecated: 07/01/2020 now handled in the linphone SDK directly
Declaration
Swift
@available(*, deprecated) public func audioRouteChanged()
-
Gets the default ephemeral message mode @core core the linphone core.
Declaration
Swift
public func chatRoomGetDefaultEphemeralMode() -> ChatRoomEphemeralMode
Return Value
the default ephemeral message mode
ChatRoomEphemeralMode
-
Sets the default ephemeral message mode.
Declaration
Swift
public func chatRoomSetDefaultEphemeralMode(mode: ChatRoomEphemeralMode)
Parameters
mode
default ephemeral message mode
ChatRoomEphemeralMode
-
Checks if a new version of the application is available.
Declaration
Swift
public func checkForUpdate(currentVersion: String)
Parameters
currentVersion
The current version of the application
-
Erase all account from config.
Declaration
Swift
public func clearAccounts()
-
Clear all authentication information.
Declaration
Swift
public func clearAllAuthInfo()
-
Erase the call log.
Declaration
Swift
public func clearCallLogs()
-
Erase all LDAP from the configuration.
Declaration
Swift
public func clearLdaps()
-
Erase all proxies from config.
Declaration
Swift
public func clearProxyConfig()
-
Writes the config file to disk.
Declaration
Swift
public func configSync() throws
Return Value
0 if successful, -1 otherwise
-
Special function to configure audio session with default settings. Must be called in ProviderDelegate’s callbacks when answer an incoming call and start an outgoing call.
Declaration
Swift
public func configureAudioSession()
-
Create an account using given parameters, see createAccountParams().
Declaration
Swift
public func createAccount(params: AccountParams) throws -> Account
Parameters
params
AccountParams
objectReturn Value
Account
with default values set -
Create a
AccountCreator
and set Linphone Request callbacks.Declaration
Swift
public func createAccountCreator(xmlrpcUrl: String?) throws -> AccountCreator
Parameters
xmlrpcUrl
The URL to the XML-RPC server.
Return Value
The new
AccountCreator
object. -
Create an account params using default values from Linphone core.
Declaration
Swift
public func createAccountParams() throws -> AccountParams
Return Value
AccountParams
with default values set -
Creates a fake
CallLog
.Declaration
Parameters
from
Address
of callerto
Address
of calleedir
Call.Dir
of callduration
call length in seconds
startTime
timestamp of call start time
connectedTime
timestamp of call connection
status
Call.Status
of callvideoEnabled
whether video was enabled or not for this call
quality
call quality
Return Value
a
CallLog
object -
Create a
CallParams
suitable for inviteWithParams(), linphone_core_accept_call_with_params, linphone_core_accept_early_media_with_params or linphone_core_accept_call_update. The parameters are initialized according to the currentCore
configuration and the last used localCallParams
, the ones passed through Call.update(), Call.acceptWithParams() or linphone_call_accept_update_with_params().Declaration
Swift
public func createCallParams(call: Call?) throws -> CallParams
Parameters
call
Call
for which the parameters are to be build, or nil in the case where the parameters are to be used for a new outgoing call.Return Value
A new
CallParams
object. -
Create a chat room.
Declaration
Swift
public func createChatRoom(params: ChatRoomParams, localAddr: Address?, participants: [Address]) throws -> ChatRoom
Parameters
params
The chat room creation parameters
ChatRoomParams
localAddr
Address
representing the local proxy configuration to use for the chat room creation or nilparticipants
The initial list of participants of the chat room.
Return Value
The newly created chat room (can be an existing one if backend is Basic) or nil.
-
Create a chat room.
- deprecated: 02/07/2020, use createChatRoom() instead
Declaration
Swift
@available(*, deprecated) public func createChatRoom(params: ChatRoomParams, localAddr: Address, subject: String, participants: [Address]) throws -> ChatRoom
Parameters
params
The chat room creation parameters
ChatRoomParams
localAddr
Address
representing the local proxy configuration to use for the chat room creationsubject
The subject of the group chat room
participants
The initial list of participants of the chat room
Return Value
The newly created chat room.
-
Create a chat room.
- deprecated: 02/07/2020, use createChatRoom() instead
Declaration
Swift
@available(*, deprecated) public func createChatRoom(params: ChatRoomParams, subject: String, participants: [Address]) throws -> ChatRoom
Parameters
params
The chat room creation parameters
ChatRoomParams
participants
The initial list of participants of the chat room.
Return Value
The newly created chat room.
-
- deprecated: 02/07/2020, use createChatRoom() instead
Declaration
Parameters
subject
The subject of the group chat room
participants
The initial list of participants of the chat room.
Return Value
The newly created chat room.
-
- deprecated: 02/07/2020, use createChatRoom() instead
Declaration
Swift
@available(*, deprecated) public func createChatRoom(params: ChatRoomParams, localAddr: Address, participant: Address) throws -> ChatRoom
Parameters
params
The chat room creation parameters
ChatRoomParams
localAddr
Address
representing the local proxy configuration to use for the chat room creationparticipant
Address
representing the initial participant to add to the chat roomReturn Value
The newly created chat room.
-
Create some default conference parameters for instanciating a conference with createConferenceWithParams().
Declaration
Swift
public func createConferenceParams() throws -> ConferenceParams
Return Value
a
ConferenceParams
object. -
Create a conference.
Declaration
Swift
public func createConferenceWithParams(params: ConferenceParams) throws -> Conference
Parameters
params
Parameters of the conference. See
ConferenceParams
.Return Value
A pointer on the freshly created conference
Conference
. That object will be automatically freed by the core after calling terminateConference(). -
Creates and returns the default chat room parameters.
Declaration
Swift
public func createDefaultChatRoomParams() throws -> ChatRoomParams
Return Value
A
ChatRoomParams
object -
Create a new empty
FriendList
object.Declaration
Swift
public func createFriendList() throws -> FriendList
Return Value
A new
FriendList
object. -
Creates an empty info message.
Declaration
Swift
public func createInfoMessage() throws -> InfoMessage
Return Value
a new LinphoneInfoMessage.
The info message can later be filled with information using InfoMessage.addHeader() or InfoMessage.setContent(), and finally sent with linphone_core_send_info_message(). -
Create a LDAP params using default values from Linphone core. Check #linphone_ldap_params to update values. In order to add a new LDAP configuration to Magic search, these parameters must be passed to linphone_core_create_ldap_with_params. Or, use Ldap.setParams(). The newly created LDAP from createLdap().
Declaration
Swift
public func createLdapParams() throws -> LdapParams
Return Value
LdapParams
with default values set. -
Create a LDAP search using given parameters and store them in the configuration file.
Declaration
Swift
public func createLdapWithParams(params: LdapParams) throws -> Ldap
Parameters
params
LdapParams
objectReturn Value
Ldap
with default values set -
Create an independent media file player. This player support WAVE and MATROSKA formats.
Declaration
Swift
public func createLocalPlayer(soundCardName: String?, videoDisplayName: String?, windowId: UnsafeMutableRawPointer?) throws -> Player
Parameters
soundCardName
Playback sound card. If nil, the ringer sound card set in
Core
will be usedvideoDisplayName
Video display. If nil, the video display set in
Core
will be usedwindowId
Id of the drawing window. Depend of video out
Return Value
A pointer on the new instance. nil if failed.
-
Create a
MagicSearch
object.Declaration
Swift
public func createMagicSearch() throws -> MagicSearch
Return Value
The created
MagicSearch
object -
Create an out-of-dialog notification, specifying the destination resource, the event name. The notification can be send with Event.notify().
Parameters
resource
the destination resource
event
the event name
Return Value
a
Event
holding the context of the notification. -
Create a publish context for a one-shot publish. After being created, the publish must be sent using Event.sendPublish(). The
Event
is automatically terminated when the publish transaction is finished, either with success or failure. The application must not call Event.terminate() for such one-shot publish.Declaration
Parameters
resource
the resource uri for the event
event
the event name
Return Value
the
Event
holding the context of the publish. -
Create a
PresenceActivity
with the given type and description.Declaration
Swift
public func createPresenceActivity(acttype: PresenceActivityType, description: String?) throws -> PresenceActivity
Parameters
acttype
The
PresenceActivityType
to set for the activity.description
An additional description of the activity to set for the activity. Can be nil if no additional description is to be added.
Return Value
The created
PresenceActivity
object. -
Create a default LinphonePresenceModel.
Declaration
Swift
public func createPresenceModel() throws -> PresenceModel
Return Value
The created
PresenceModel
object. -
Create a
PresenceModel
with the given activity type and activity description.Declaration
Swift
public func createPresenceModelWithActivity(acttype: PresenceActivityType, description: String?) throws -> PresenceModel
Parameters
acttype
The
PresenceActivityType
to set for the activity of the created model.description
An additional description of the activity to set for the activity. Can be nil if no additional description is to be added.
Return Value
The created
PresenceModel
object. -
Create a
PresenceModel
with the given activity type, activity description, note content and note language.Declaration
Swift
public func createPresenceModelWithActivityAndNote(acttype: PresenceActivityType, description: String?, note: String, lang: String?) throws -> PresenceModel
Parameters
acttype
The
PresenceActivityType
to set for the activity of the created model.description
An additional description of the activity to set for the activity. Can be nil if no additional description is to be added.
note
The content of the note to be added to the created model.
lang
The language of the note to be added to the created model.
Return Value
The created
PresenceModel
object. -
Create a
PresenceNote
with the given content and language.Declaration
Swift
public func createPresenceNote(content: String, lang: String?) throws -> PresenceNote
Parameters
content
The content of the note to be created.
lang
The language of the note to be created.
Return Value
The created
PresenceNote
object. -
Create a
PresencePerson
with the given id.Declaration
Swift
public func createPresencePerson(id: String) throws -> PresencePerson
Parameters
id
The id of the person to be created.
Return Value
The created
PresencePerson
object. -
Create a
PresenceService
with the given id, basic status and contact.Declaration
Swift
public func createPresenceService(id: String, basicStatus: PresenceBasicStatus, contact: String) throws -> PresenceService
Parameters
id
The id of the service to be created.
basicStatus
The basic status of the service to be created.
contact
A string containing a contact information corresponding to the service to be created.
Return Value
The created
PresenceService
object. -
Create a proxy config with default values from Linphone core.
Declaration
Swift
public func createProxyConfig() throws -> ProxyConfig
Return Value
ProxyConfig
with default values set -
Create a publish context for an event state. After being created, the publish must be sent using Event.sendPublish(). After expiry, the publication is refreshed unless it is terminated before.
Declaration
Parameters
resource
the resource uri for the event
event
the event name
expires
the lifetime of event being published, -1 if no associated duration, in which case it will not be refreshed.
Return Value
the
Event
holding the context of the publish. -
Create a media file recorder. This recorder support WAVE and MATROSKA formats.
Declaration
Swift
public func createRecorder(params: RecorderParams) throws -> Recorder
Parameters
params
The
RecorderParams
that will contains all recorder parameters.Return Value
A pointer on the new instance. nil if failed.
-
Create a recorder params that will hold parameters. This recorder support WAVE and MATROSKA formats.
Declaration
Swift
public func createRecorderParams() throws -> RecorderParams
Return Value
A pointer on the newly created instance.
-
Create an outgoing subscription, specifying the destination resource, the event name, and an optional content body. If accepted, the subscription runs for a finite period, but is automatically renewed if not terminated before. Unlike subscribe() the subscription isn’t sent immediately. It will be send when calling Event.sendSubscribe().
Declaration
Parameters
resource
the destination resource
event
the event name
expires
the whished duration of the subscription
Return Value
a
Event
holding the context of the created subcription. -
Create an outgoing subscription, specifying the destination resource, the event name, and an optional content body. If accepted, the subscription runs for a finite period, but is automatically renewed if not terminated before. Unlike subscribe() the subscription isn’t sent immediately. It will be send when calling Event.sendSubscribe().
Declaration
Swift
public func createSubscribe(resource: Address, proxy: ProxyConfig, event: String, expires: Int) throws -> Event
Parameters
resource
the destination resource
proxy
the proxy configuration to use
event
the event name
expires
the whished duration of the subscription
Return Value
a
Event
holding the context of the created subcription. -
Create a
XmlRpcSession
for a given url.Declaration
Swift
public func createXmlRpcSession(url: String) throws -> XmlRpcSession
Parameters
url
The URL to the XML-RPC server. Must be NON nil.
Return Value
The new
XmlRpcSession
object. -
Sets device_token when application didRegisterForRemoteNotificationsWithDeviceToken (IOS only).
Declaration
Swift
public func didRegisterForRemotePush(deviceToken: UnsafeMutableRawPointer?)
Parameters
deviceToken
(NSData *).
-
Sets device_token when application didRegisterForRemoteNotificationsWithDeviceToken (IOS only).
Declaration
Swift
public func didRegisterForRemotePushWithStringifiedToken(deviceTokenStr: String?)
Parameters
deviceTokenStr
extracted from the Data objectf received in didRegisterForRemoteNotificationsWithDeviceToken ios function. Append “:remote” after data formating..
-
Inconditionnaly disable incoming chat messages.
Declaration
Swift
public func disableChat(denyReason: Reason)
Parameters
denyReason
the deny reason (
None
has no effect). -
Enable reception of incoming chat messages. By default it is enabled but it can be disabled with disableChat().
Declaration
Swift
public func enableChat()
-
Call this method when you receive a push notification (if you handle push notifications manually). It will ensure the proxy configs are correctly registered to the proxy server, so the call or the message will be correctly delivered.
Declaration
Swift
public func ensureRegistered()
-
This method is called by the application to notify the linphone core library when it enters background mode.
Declaration
Swift
public func enterBackground()
-
Join the local participant to the running conference.
- deprecated: 09/03/2021 Use Conference.enter() instead.
Declaration
Swift
@available(*, deprecated) public func enterConference() throws
Return Value
0 if succeeded. Negative number if failed
-
This method is called by the application to notify the linphone core library when it enters foreground mode.
Declaration
Swift
public func enterForeground()
-
Returns whether a specific file format is supported.
See
See also: linphone_core_get_supported_file_formatsDeclaration
Swift
public func fileFormatSupported(fmt: String) -> Bool
Parameters
fmt
The format extension (wav, mkv).
Return Value
true if the file format is supported, false otherwise
-
Find authentication info matching realm, username, domain criteria. First of all, (realm,username) pair are searched. If multiple results (which should not happen because realm are supposed to be unique), then domain is added to the search.
Declaration
Swift
public func findAuthInfo(realm: String?, username: String, sipDomain: String?) -> AuthInfo?
Parameters
realm
the authentication ‘realm’ (optional)
username
the SIP username to be authenticated (mandatory)
sipDomain
the SIP domain name (optional)
Return Value
a
AuthInfo
if found. -
Search from the list of current calls if a remote address match uri.
- deprecated: 27/10/2020. Use getCallByRemoteAddress2() instead.
Declaration
Swift
@available(*, deprecated) public func findCallFromUri(uri: String) -> Call?
Parameters
uri
which should match call remote uri
Return Value
Call
or nil is no match is found. -
Get the call log matching the call id, or nil if can’t be found.
Declaration
Swift
public func findCallLog(callId: String, limit: Int) -> CallLog?
Parameters
callId
Call id of the call log to find
limit
Search limit of the most recent call logs to find
Return Value
A call log matching the call id if any.
-
Get the call log matching the call id, or nil if can’t be found.
Declaration
Swift
public func findCallLogFromCallId(callId: String) -> CallLog?
Parameters
callId
Call id of the call log to find
Return Value
A call log matching the call id if any.
-
Find a chat room. No reference is transfered to the application. The
Core
keeps a reference on the chat room.- deprecated: 02/07/2020, use searchChatRoom() instead
Declaration
Parameters
peerAddr
a linphone address.
localAddr
a linphone address.
Return Value
ChatRoom
where messaging can take place. -
Find a one to one chat room. No reference is transfered to the application. The
Core
keeps a reference on the chat room.- deprecated: 02/07/2020, use searchChatRoom() instead
Declaration
Parameters
localAddr
a linphone address.
participantAddr
a linphone address.
encrypted
whether to look for an encrypted chat room or not
Return Value
ChatRoom
where messaging can take place. -
Get the call with the remote_address specified.
- deprecated: 08/07/2020 use getCallByRemoteAddress2() instead
Declaration
Swift
@available(*, deprecated) public func getCallByRemoteAddress(remoteAddress: String) -> Call?
Parameters
remoteAddress
The remote address of the call that we want to get
Return Value
The call if it has been found, nil otherwise.
-
Get the list of call logs (past calls). At the contrary of linphone_core_get_call_logs, it is your responsibility to unref the logs and free this list once you are done using it.
Declaration
Return Value
A list of
CallLog
. -
Get the list of call logs (past calls) that matches the given
Address
. At the contrary of linphone_core_get_call_logs, it is your responsibility to unref the logs and free this list once you are done using it.- deprecated: 29/10/2018 Use getCallHistory() instead.
Declaration
Parameters
address
Address
objectReturn Value
A list of
CallLog
. -
Get a chat room whose peer is the supplied address. If it does not exist yet, it will be created as a basic chat room. No reference is transfered to the application. The
Core
keeps a reference on the chat room. - Warning: This method is prone to errors, use searchChatRoom() instead- deprecated: 02/07/2020, use searchChatRoom() instead
Parameters
addr
a linphone address.
Return Value
ChatRoom
where messaging can take place. -
Get a chat room. If it does not exist yet, it will be created as a basic chat room. No reference is transfered to the application. The
Core
keeps a reference on the chat room. - Warning: This method is prone to errors, use searchChatRoom() instead- deprecated: 02/07/2020, use searchChatRoom() instead
Declaration
Parameters
peerAddr
a linphone address.
localAddr
a linphone address.
Return Value
ChatRoom
where messaging can take place. -
Get a chat room for messaging from a sip uri like sip:joe@sip.linphone.org. If it does not exist yet, it will be created as a basic chat room. No reference is transfered to the application. The
Core
keeps a reference on the chat room. - Warning: This method is prone to errors, use searchChatRoom() instead- deprecated: 02/07/2020, use searchChatRoom() instead
Declaration
Swift
@available(*, deprecated) public func getChatRoomFromUri(to: String) -> ChatRoom?
Parameters
to
The destination address for messages.
Return Value
ChatRoom
where messaging can take place. -
Retrieves the list of
Friend
from the core that has the given display name.Declaration
Swift
public func getFriendListByName(name: String) -> FriendList?
Parameters
name
the name of the list
Return Value
the first
FriendList
object or nil. -
Get the chat room we have been added into using the chat_room_addr included in the push notification body This will start the core given in parameter, iterate until the new chat room is received and return it. By default, after 25 seconds the function returns because iOS kills the app extension after 30 seconds.
Declaration
Swift
public func getNewChatRoomFromConfAddr(chatRoomAddr: String) -> ChatRoom?
Parameters
chatRoomAddr
The sip address of the chat room
Return Value
The
ChatRoom
object. -
Get the chat message with the call_id included in the push notification body This will start the core given in parameter, iterate until the message is received and return it. By default, after 25 seconds the function returns because iOS kills the app extension after 30 seconds.
Declaration
Swift
public func getNewMessageFromCallid(callId: String) -> PushNotificationMessage?
Parameters
callId
The callId of the Message SIP transaction
Return Value
The
ChatMessage
object. -
Get payload type from mime type and clock rate. This function searches in audio and video codecs for the given payload type name and clockrate.
Warning
The returned payload type is allocated as a floating reference i.e. the reference counter is initialized to 0.Declaration
Swift
public func getPayloadType(type: String, rate: Int, channels: Int) -> PayloadType?
Parameters
type
payload mime type (I.E SPEEX, PCMU, VP8)
rate
can be LINPHONE_FIND_PAYLOAD_IGNORE_RATE
channels
number of channels, can be LINPHONE_FIND_PAYLOAD_IGNORE_CHANNELS
Return Value
Returns nil if not found. If a
PayloadType
is returned, it must be released with linphone_payload_type_unref after using it. -
Search for a
ProxyConfig
by it’s idkey.Declaration
Swift
public func getProxyConfigByIdkey(idkey: String) -> ProxyConfig?
Parameters
idkey
An arbitrary idkey string associated to a proxy configuration
Return Value
the
ProxyConfig
object for the given idkey value, or nil if none found -
Get the zrtp sas validation status for a peer uri. Once the SAS has been validated or rejected, the status will never return to Unknown (unless you delete your cache)
Declaration
Swift
public func getZrtpStatus(addr: String) -> ZrtpPeerStatus
Parameters
addr
the peer uri
Return Value
- LinphoneZrtpPeerStatusUnknown: this uri is not present in cache OR during calls with the active device, SAS never was validated or rejected
-
Check whether the device has a hardware echo canceller.
Declaration
Swift
public func hasBuiltinEchoCanceller() -> Bool
Return Value
true if it does, false otherwise
-
Check whether the device is flagged has crappy opengl.
Declaration
Swift
public func hasCrappyOpengl() -> Bool
Return Value
true if crappy opengl flag is set, false otherwise
-
Tells whether there is a call running.
Declaration
Swift
public func inCall() -> Bool
Return Value
A boolean value telling whether a call is currently running or not
-
Constructs a
Address
from the given string if possible. In case of just a username, characters will be unescaped. If a phone number is detected, it will be flattened. sip: or sips: prefix will be added if not present. Finally, @domain will be added if not present using default proxy config. - See also: ProxyConfig.normalizeSipUri() for documentation.Declaration
Swift
public func interpretUrl(url: String) -> Address?
Parameters
url
the url to parse
Return Value
the
Address
matching the url or nil in case of failure. -
Initiates an outgoing call. The application doesn’t own a reference to the returned LinphoneCall object. Use linphone_call_ref to safely keep the LinphoneCall pointer valid within your application.
Declaration
Swift
public func invite(url: String) -> Call?
Parameters
url
The destination of the call (sip address, or phone number).
Return Value
A
Call
object or nil in case of failure. -
Initiates an outgoing call given a destination
Address
TheAddress
can be constructed directly using linphone_address_new, or created by interpretUrl(). The application doesn’t own a reference to the returnedCall
object. Use linphone_call_ref to safely keep theCall
pointer valid within your application.Parameters
addr
The destination of the call (sip address).
Return Value
A
Call
object or nil in case of failure. -
Initiates an outgoing call given a destination
Address
TheAddress
can be constructed directly using linphone_address_new, or created by interpretUrl(). The application doesn’t own a reference to the returnedCall
object. Use linphone_call_ref to safely keep theCall
pointer valid within your application. If the proxy is not specified in parameters, the caller proxy will be automatically selected by finding what is the best to reach the destination of the call.Declaration
Swift
public func inviteAddressWithParams(addr: Address, params: CallParams) -> Call?
Parameters
addr
The destination of the call (sip address).
params
Call parameters
Return Value
A
Call
object or nil in case of failure. -
Initiates an outgoing call according to supplied call parameters The application doesn’t own a reference to the returned
Call
object. Use linphone_call_ref to safely keep theCall
pointer valid within your application.Declaration
Swift
public func inviteWithParams(url: String, params: CallParams) -> Call?
Parameters
url
The destination of the call (sip address, or phone number).
params
the
CallParams
call parametersReturn Value
A
Call
object or nil in case of failure. -
Tells whether a content type is supported.
Declaration
Swift
public func isContentTypeSupported(contentType: String) -> Bool
Parameters
contentType
The content type to check
Return Value
A boolean value telling whether the specified content type is supported or not.
-
Check if media encryption is supported.
Declaration
Swift
public func isMediaEncryptionSupported(menc: MediaEncryption) -> Bool
Parameters
menc
The media encryption policy to be used.
Return Value
true if the media encryption is supported, false otherwise
-
Checks if the given media filter is loaded and usable. This is for advanced users of the library, mainly to expose mediastreamer video filter status.
Declaration
Swift
public func isMediaFilterSupported(filtername: String) -> Bool
Parameters
filtername
the filter name
Return Value
true if the filter is loaded and usable, false otherwise
-
Main loop function. It is crucial that your application call it periodically. iterate() performs various backgrounds tasks:
Declaration
Swift
public func iterate()
-
Tells if LDAP is available.
Declaration
Swift
public func ldapAvailable() -> Bool
Return Value
true if LDAP is available, false otherwise
-
Make the local participant leave the running conference.
- deprecated: 09/03/2021 Use Conference.leave() instead.
Declaration
Swift
@available(*, deprecated) public func leaveConference() throws
Return Value
0 if succeeded. Negative number if failed
-
Tells if LIME X3DH is available.
Declaration
Swift
public func limeX3DhAvailable() -> Bool
-
Update current config with the content of a xml config file.
Declaration
Swift
public func loadConfigFromXml(xmlUri: String)
Parameters
xmlUri
the path to the xml file
-
Check if a media encryption type is supported.
Declaration
Swift
public func mediaEncryptionSupported(menc: MediaEncryption) -> Bool
Parameters
menc
Return Value
whether a media encryption scheme is supported by the
Core
engine -
Migrates the call logs from the linphonerc to the database if not done yet.
Declaration
Swift
public func migrateLogsFromRcToDb()
-
Migrate configuration so that all SIP transports are enabled. Versions of linphone < 3.7 did not support using multiple SIP transport simultaneously. This function helps application to migrate the configuration so that all transports are enabled. Existing proxy configuration are added a transport parameter so that they continue using the unique transport that was set previously. This function must be used just after creating the core, before any call to iterate()
Declaration
Swift
public func migrateToMultiTransport() throws
Return Value
1 if migration was done, 0 if not done because unnecessary or already done, -1 in case of error.
-
Notify all friends that have subscribed.
Declaration
Swift
public func notifyAllFriends(presence: PresenceModel)
Parameters
presence
PresenceModel
to notify -
Notifies the upper layer that a presence status has been received by calling the appropriate callback if one has been set. This method is for advanced usage, where customization of the liblinphone’s internal behavior is required.
Declaration
Swift
public func notifyNotifyPresenceReceived(linphoneFriend: Friend)
Parameters
linphoneFriend
the
Friend
whose presence information has been received. -
Notifies the upper layer that a presence model change has been received for the uri or telephone number given as a parameter, by calling the appropriate callback if one has been set. This method is for advanced usage, where customization of the liblinphone’s internal behavior is required.
Declaration
Swift
public func notifyNotifyPresenceReceivedForUriOrTel(linphoneFriend: Friend, uriOrTel: String, presenceModel: PresenceModel)
Parameters
linphoneFriend
the
Friend
whose presence information has been received.uriOrTel
telephone number or sip uri
presenceModel
the
PresenceModel
that has been modified -
Pause all currently running calls.
Declaration
Swift
public func pauseAllCalls() throws
Return Value
0
-
Plays a dtmf sound to the local user.
Declaration
Swift
public func playDtmf(dtmf: CChar, durationMs: Int)
Parameters
dtmf
DTMF to play [‘0’..‘16’] | ‘#’ | ‘#’
durationMs
Duration in ms, -1 means play until next further call to stopDtmf()
-
Plays an audio file to the local user. This function works at any time, during calls, or when no calls are running. It doesn’t request the underlying audio system to support multiple playback streams.
Declaration
Swift
public func playLocal(audiofile: String) throws
Parameters
audiofile
The path to an audio file in wav PCM 16 bit format
Return Value
0 on success, -1 on error
-
Empties sound resources to allow a new call to be accepted. This function is autyomatically called by the core if the media resource mode is set to unique.
Declaration
Swift
public func preemptSoundResources() -> Int
Return Value
An integer returning the exit value. If it is 0, sound resources have been emptied. Otherwise, sound resources are busy and cannot be freed immediately.
-
Call generic OpenGL render for a given core.
Declaration
Swift
public func previewOglRender()
-
Publish an event state. This first create a
Event
with createPublish() and calls Event.sendPublish() to actually send it. After expiry, the publication is refreshed unless it is terminated before.Declaration
Parameters
resource
the resource uri for the event
event
the event name
expires
the lifetime of event being published, -1 if no associated duration, in which case it will not be refreshed.
body
the actual published data
Return Value
the
Event
holding the context of the publish. -
Gets keep alive interval of real time text.
Declaration
Swift
public func realtimeTextGetKeepaliveInterval() -> UInt
Return Value
keep alive interval of real time text.
-
Set keep alive interval for real time text.
Declaration
Swift
public func realtimeTextSetKeepaliveInterval(interval: UInt)
Parameters
interval
The keep alive interval of real time text, 25000 by default.
-
force registration refresh to be initiated upon next iterate
Declaration
Swift
public func refreshRegisters()
-
Reload mediastreamer2 plugins from specified directory.
Declaration
Swift
public func reloadMsPlugins(path: String?)
Parameters
path
the path from where plugins are to be loaded, pass nil to use default (compile-time determined) plugin directory.
-
Update detection of sound devices. Use this function when the application is notified of USB plug events, so that list of available hardwares for sound playback and capture is updated.
Declaration
Swift
public func reloadSoundDevices()
-
Update detection of camera devices. Use this function when the application is notified of USB plug events, so that list of available hardwares for video capture is updated.
Declaration
Swift
public func reloadVideoDevices()
-
Remove support for the specified content type. It is the application responsibility to handle it correctly afterwards.
Declaration
Swift
public func removeContentTypeSupport(contentType: String)
Parameters
contentType
The content type to remove support for
-
Removes a friend list.
Declaration
Swift
public func removeFriendList(list: FriendList)
Parameters
list
FriendList
object -
Remove a call from the conference.
Declaration
Swift
public func removeFromConference(call: Call) throws
Parameters
call
a call that has been previously merged into the conference.
After removing the remote participant belonging to the supplied call, the call becomes a normal call in paused state. If one single remote participant is left alone together with the local user in the conference after the removal, then the conference is automatically transformed into a simple call in StreamsRunning state. The conference’s resources are then automatically destroyed. In other words, unless leaveConference() is explicitly called, the last remote participant of a conference is automatically put in a simple call in running state.Return Value
0 if successful, -1 otherwise.
-
Remove a LDAP from the configuration.
Declaration
Swift
public func removeLdap(ldap: Ldap)
Parameters
ldap
The LDAP to remove.
-
Remove the given linphone specs from the list of functionalities the linphone client supports.
Declaration
Swift
public func removeLinphoneSpec(spec: String)
Parameters
spec
The spec to remove
-
Removes a proxy configuration.
Core
will then automatically unregister and place the proxy configuration on a deleted list. For that reason, a removed proxy does NOT need to be freed.Declaration
Swift
public func removeProxyConfig(config: ProxyConfig)
Parameters
config
the
ProxyConfig
to remove -
Remove a supported tag.
See
See also: addSupportedTag()Declaration
Swift
public func removeSupportedTag(tag: String)
Parameters
tag
The tag to remove
-
Reset the counter of missed calls.
Declaration
Swift
public func resetMissedCallsCount()
-
Find a chat room.
Declaration
Swift
public func searchChatRoom(params: ChatRoomParams?, localAddr: Address?, remoteAddr: Address?, participants: [Address]?) -> ChatRoom?
Parameters
params
The chat room parameters to match
ChatRoomParams
or nillocalAddr
Address
representing the local proxy configuration or nilremoteAddr
Address
to search for or nilparticipants
The participants that must be present in the chat room to find.
Return Value
A matching chat room or nil if none matches.
-
Find a conference.
Declaration
Swift
public func searchConference(params: ConferenceParams?, localAddr: Address?, remoteAddr: Address?, participants: [Address]?) -> Conference?
Parameters
params
The conference parameters to match
ConferenceParams
or nillocalAddr
Address
representing the local proxy configuration or nilremoteAddr
Address
to search for or nilparticipants
The participants that must be present in the chat room to find
Return Value
A pointer on
Conference
satisfying the non-nil function arguments or nil if none matches -
Send the conference invitations to all participants as an ICS file.
Declaration
Swift
public func sendConferenceInformation(conferenceInformation: ConferenceInfo, text: String?)
Parameters
conferenceInformation
The
ConferenceInfo
text
An optional text to be added to the sent chat message
-
Sets the UDP port range from which to randomly select the port used for audio streaming.
Declaration
Swift
public func setAudioPortRange(minPort: Int, maxPort: Int)
Parameters
minPort
The lower bound of the audio port range to use
maxPort
The upper bound of the audio port range to use
-
Assign an audio file to be played locally upon call failure, for a given reason.
Declaration
Swift
public func setCallErrorTone(reason: Reason, audiofile: String?)
Parameters
reason
the
Reason
representing the failure error code.audiofile
a wav file to be played when such call failure happensd or nil to disable it.
-
Set the rectangle where the decoder will search a QRCode.
Declaration
Swift
public func setQrcodeDecodeRect(x: Int, y: Int, w: Int, h: Int)
Parameters
x
axis
y
axis
w
width
h
height
-
Sets the UDP port range from which to randomly select the port used for text streaming.
Declaration
Swift
public func setTextPortRange(minPort: Int, maxPort: Int)
Parameters
minPort
The lower bound of the text port range to use
maxPort
The upper bound of the text port range to use
-
Assign an audio file to be played as a specific tone id. This function typically allows to customize telephony tones per country.
Declaration
Swift
public func setTone(toneId: ToneID, audiofile: String?)
Parameters
toneId
the #LinphoneToneId
audiofile
a wav file to be played or nil to disable it.
-
Set the user agent string used in SIP messages. Set the user agent string used in SIP messages as “[ua_name]/[version]”. No slash character will be printed if nil is given to “version”. If nil is given to “ua_name” and “version” both, the User-agent header will be empty. This function should be called just after linphone_factory_create_core ideally.
Declaration
Swift
public func setUserAgent(name: String?, version: String?)
Parameters
name
Name of the user agent.
version
Version of the user agent.
-
Sets the UDP port range from which to randomly select the port used for video streaming.
Declaration
Swift
public func setVideoPortRange(minPort: Int, maxPort: Int)
Parameters
minPort
The lower bound of the video port range to use
maxPort
The upper bound of the video port range to use
-
Tells whether a specified sound device can capture sound.
- deprecated: 08/07/2020 use
AudioDevice
API instead()
Declaration
Swift
@available(*, deprecated) public func soundDeviceCanCapture(device: String) -> Bool
Parameters
device
the device name as returned by linphone_core_get_sound_devices
Return Value
A boolean value telling whether the specified sound device can capture sound
- deprecated: 08/07/2020 use
-
Tells whether a specified sound device can play sound.
- deprecated: 08/07/2020 use
AudioDevice
API instead()
Declaration
Swift
@available(*, deprecated) public func soundDeviceCanPlayback(device: String) -> Bool
Parameters
device
the device name as returned by linphone_core_get_sound_devices
Return Value
A boolean value telling whether the specified sound device can play sound
- deprecated: 08/07/2020 use
-
Check if a call will need the sound resources in near future (typically an outgoing call that is awaiting response). In liblinphone, it is not possible to have two independant calls using sound device or camera at the same time. In order to prevent this situation, an application can use soundResourcesLocked() to know whether it is possible at a given time to start a new outgoing call. When the function returns true, an application should not allow the user to start an outgoing call.
Declaration
Swift
public func soundResourcesLocked() -> Bool
Return Value
A boolean value telling whether a call will need the sound resources in near future
-
Start a
Core
object after it has been instantiated and not automatically started. Also re-initialize aCore
object that has been stopped using stop(). Must be called only ifGlobalState
is either Ready of Off. State will changed to Startup, Configuring and then On.Declaration
Swift
public func start() throws
Return Value
0: success, -1: global failure, -2: could not connect database
-
Start recording the running conference.
- deprecated: 14/09/2021 Use Conference.startRecording() instead.
Declaration
Swift
@available(*, deprecated) public func startConferenceRecording(path: String) throws
Parameters
path
Path to the file where the recording will be written
Return Value
0 if succeeded. Negative number if failed
-
Starts an echo calibration of the sound devices, in order to find adequate settings for the echo canceler automatically.
Declaration
Swift
public func startEchoCancellerCalibration() throws
Return Value
LinphoneStatus whether calibration has started or not.
-
Start the simulation of call to test the latency with an external device.
Declaration
Swift
public func startEchoTester(rate: UInt) throws
Parameters
rate
Sound sample rate.
Return Value
-1 in case of failure, 1 otherwise.
-
Stop a
Core
object after it has been instantiated and started. If stopped, it can be started again using start(). Must be called only ifGlobalState
is either On. State will changed to Shutdown and then Off.Declaration
Swift
public func stop()
-
Stop asynchronously a
Core
object after it has been instantiated and started. State changes to Shutdown then iterate() must be called to allow the Core to end asynchronous tasks (terminate call, etc.). When all tasks are finished, State will change to Off. Must be called only ifGlobalState
is On. WhenGlobalState
is OffCore
can be started again using start().Declaration
Swift
public func stopAsync()
-
Stop recording the running conference.
- deprecated: 14/09/2021 Use Conference.stopRecording() instead.
Declaration
Swift
@available(*, deprecated) public func stopConferenceRecording() throws
Return Value
0 if succeeded. Negative number if failed
-
Stops playing a dtmf started by playDtmf().
Declaration
Swift
public func stopDtmf()
-
Stop the simulation of call.
Declaration
Swift
public func stopEchoTester() throws
-
Whenever the liblinphone is playing a ring to advertise an incoming call or ringback of an outgoing call, this function stops the ringing. Typical use is to stop ringing when the user requests to ignore the call.
Declaration
Swift
public func stopRinging()
-
Create an outgoing subscription, specifying the destination resource, the event name, and an optional content body. If accepted, the subscription runs for a finite period, but is automatically renewed if not terminated before.
Declaration
Parameters
resource
the destination resource
event
the event name
expires
the whished duration of the subscription
body
an optional body, may be nil.
Return Value
a
Event
holding the context of the created subcription. -
Take a photo of currently from capture device and write it into a jpeg file. Note that the snapshot is asynchronous, an application shall not assume that the file is created when the function returns.
Declaration
Swift
public func takePreviewSnapshot(file: String) throws
Parameters
file
a path where to write the jpeg content.
Return Value
0 if successfull, -1 otherwise (typically if jpeg format is not supported).
-
Terminates all the calls.
Declaration
Swift
public func terminateAllCalls() throws
Return Value
0
-
Terminate the running conference. If it is a local conference, all calls inside it will become back separate calls and will be put in #LinphoneCallPaused state. If it is a conference involving a focus server, all calls inside the conference will be terminated.
Declaration
Swift
public func terminateConference() throws
Return Value
0 if succeeded. Negative number if failed
-
Upload the log collection to the configured server url.
Declaration
Swift
public func uploadLogCollection()
-
Tells the core to use a separate window for local camera preview video, instead of inserting local view within the remote video window.
Declaration
Swift
public func usePreviewWindow(yesno: Bool)
Parameters
yesno
true to use a separate window, false to insert the preview in the remote video window.
-
Specify whether the tls server certificate must be verified when connecting to a SIP/TLS server.
Declaration
Swift
public func verifyServerCertificates(yesno: Bool)
Parameters
yesno
A boolean value telling whether the tls server certificate must be verified
-
Specify whether the tls server certificate common name must be verified when connecting to a SIP/TLS server.
Declaration
Swift
public func verifyServerCn(yesno: Bool)
Parameters
yesno
A boolean value telling whether the tls server certificate common name must be verified
-
Test if video is supported.
Declaration
Swift
public func videoSupported() -> Bool
Return Value
true if the library was built with video support, false otherwise