core.h 241 KB
Newer Older
aymeric's avatar
aymeric committed
1 2
/*
linphone
3
Copyright (C) 2000 - 2010 Simon MORLAT (simon.morlat@linphone.org)
aymeric's avatar
aymeric committed
4 5 6 7 8 9 10 11 12 13 14 15 16

This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
17
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
aymeric's avatar
aymeric committed
18
*/
19

aymeric's avatar
aymeric committed
20 21 22 23 24 25
#ifndef LINPHONECORE_H
#define LINPHONECORE_H

#include "ortp/ortp.h"
#include "ortp/payloadtype.h"
#include "mediastreamer2/mscommon.h"
smorlat's avatar
smorlat committed
26
#include "mediastreamer2/msvideo.h"
27
#include "mediastreamer2/mediastream.h"
28
#include "mediastreamer2/bitratecontrol.h"
Ghislain MARY's avatar
Ghislain MARY committed
29

30 31
#include "linphone/defs.h"
#include "linphone/types.h"
32
#include "linphone/callbacks.h"
33
#include "linphone/sipsetup.h"
34 35

#include "linphone/account_creator.h"
36
#include "linphone/account_creator_service.h"
rosset claire's avatar
rosset claire committed
37

38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53
#include "linphone/buffer.h"
#include "linphone/call.h"
#include "linphone/call_log.h"
#include "linphone/call_params.h"
#include "linphone/call_stats.h"
#include "linphone/chat.h"
#include "linphone/conference.h"
#include "linphone/dictionary.h"
#include "linphone/error_info.h"
#include "linphone/event.h"
#include "linphone/factory.h"
#include "linphone/friend.h"
#include "linphone/friendlist.h"
#include "linphone/im_encryption_engine.h"
#include "linphone/im_notif_policy.h"
#include "linphone/info_message.h"
54
#include "linphone/logging.h"
55
#include "linphone/lpconfig.h"
56 57 58 59 60 61 62 63
#include "linphone/misc.h"
#include "linphone/nat_policy.h"
#include "linphone/payload_type.h"
#include "linphone/player.h"
#include "linphone/presence.h"
#include "linphone/proxy_config.h"
#include "linphone/ringtoneplayer.h"
#include "linphone/vcard.h"
64
#include "linphone/video_definition.h"
65
#include "linphone/xmlrpc.h"
66
#include "linphone/headers.h"
67

68 69
// For migration purpose.
#include "linphone/api/c-api.h"
70

aymeric's avatar
aymeric committed
71 72 73 74
#ifdef __cplusplus
extern "C" {
#endif

75
/**
76
 * Safely down-cast a belle_sip_object_t into #LinphoneCore
77 78 79
 * @ingroup initializing
 */
#define LINPHONE_CORE(object) BELLE_SIP_CAST(object, LinphoneCore)
80

81

jehan's avatar
jehan committed
82
/**
83 84 85 86
 * Create a #LinphoneAddress object by parsing the user supplied address, given as a string.
 * @param[in] lc #LinphoneCore object
 * @param[in] address String containing the user supplied address
 * @return The create #LinphoneAddress object
87
 * @ingroup linphone_address
88
 */
89
LINPHONE_PUBLIC LinphoneAddress * linphone_core_create_address(LinphoneCore *lc, const char *address);
90 91


92
/**
93 94
 * @addtogroup misc
 * @{
Simon Morlat's avatar
Simon Morlat committed
95
 */
96 97 98 99

/**
 * Create an independent media file player.
 * This player support WAVE and MATROSKA formats.
100 101 102
 * @param lc A #LinphoneCore object
 * @param sound_card_name Playback sound card. If NULL, the ringer sound card set in #LinphoneCore will be used
 * @param video_display_name Video display. If NULL, the video display set in #LinphoneCore will be used
103 104 105
 * @param window_id Id of the drawing window. Depend of video out
 * @return A pointer on the new instance. NULL if faild.
 */
106
LINPHONE_PUBLIC LinphonePlayer *linphone_core_create_local_player(LinphoneCore *lc, const char *sound_card_name, const char *video_display_name, void *window_id);
107

108 109
/**
 * Creates an empty info message.
110
 * @param lc the #LinphoneCore
111 112 113 114 115
 * @return a new LinphoneInfoMessage.
 *
 * The info message can later be filled with information using linphone_info_message_add_header() or linphone_info_message_set_content(),
 * and finally sent with linphone_core_send_info_message().
**/
116
LINPHONE_PUBLIC LinphoneInfoMessage *linphone_core_create_info_message(LinphoneCore*lc);
117

118 119 120 121 122 123 124 125
/**
 * Create a #LinphoneMagicSearch object.
 * @param[in] lc #LinphoneCore object
 * @return The create #LinphoneMagicSearch object
 * @ingroup misc
 */
LINPHONE_PUBLIC LinphoneMagicSearch *linphone_core_create_magic_search(LinphoneCore *lc);

Ghislain MARY's avatar
Ghislain MARY committed
126 127
/**
 * Checks if a new version of the application is available.
128
 * @param lc #LinphoneCore object
Ghislain MARY's avatar
Ghislain MARY committed
129 130 131 132
 * @param current_version The current version of the application
 */
LINPHONE_PUBLIC void linphone_core_check_for_update(LinphoneCore *lc, const char *current_version);

133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157
/**
 * Return the global unread chat message count.
 * @param[in] lc #LinphoneCore object.
 * @return The global unread chat message count.
 */
LINPHONE_PUBLIC int linphone_core_get_unread_chat_message_count (const LinphoneCore *lc);

/**
 * Return the unread chat message count for a given local address.
 * @param[in] lc #LinphoneCore object.
 * @param[in] address #LinphoneAddress object.
 * @return The unread chat message count.
 */
LINPHONE_PUBLIC int linphone_core_get_unread_chat_message_count_from_local (
	const LinphoneCore *lc,
	const LinphoneAddress *address
);

/**
 * Return the unread chat message count for all active local address. (Primary contact + proxy configs.)
 * @param[in] lc #LinphoneCore object.
 * @return The unread chat message count.
 */
LINPHONE_PUBLIC int linphone_core_get_unread_chat_message_count_from_active_locals (const LinphoneCore *lc);

Ghislain MARY's avatar
Ghislain MARY committed
158 159 160
/**
 * @}
 */
161

162 163
/**
 * Get the remote address of the current call.
164
 * @param[in] lc #LinphoneCore object.
165 166 167
 * @return The remote address of the current call or NULL if there is no current call.
 * @ingroup call_control
 */
168
LINPHONE_PUBLIC const LinphoneAddress * linphone_core_get_current_call_remote_address(LinphoneCore *lc);
169

170

Simon Morlat's avatar
Simon Morlat committed
171 172 173 174 175
/**
 * @addtogroup initializing
 * @{
**/

176 177
/**
 * Callback prototype
178
 */
Simon Morlat's avatar
Simon Morlat committed
179
typedef void (*LinphoneCoreCbFunc)(LinphoneCore *lc,void * user_data);
180

smorlat's avatar
smorlat committed
181 182
/**
 * This structure holds all callbacks that the application should implement.
183
 * None is mandatory.
184
 * @donotwrap
smorlat's avatar
smorlat committed
185
**/
Simon Morlat's avatar
Simon Morlat committed
186
typedef struct _LinphoneCoreVTable{
187 188 189
	LinphoneCoreGlobalStateChangedCb global_state_changed; /**<Notifies global state changes*/
	LinphoneCoreRegistrationStateChangedCb registration_state_changed;/**<Notifies registration state changes*/
	LinphoneCoreCallStateChangedCb call_state_changed;/**<Notifies call state changes*/
190
	LinphoneCoreNotifyPresenceReceivedCb notify_presence_received; /**< Notify received presence events*/
191
	LinphoneCoreNotifyPresenceReceivedForUriOrTelCb notify_presence_received_for_uri_or_tel; /**< Notify received presence events*/
192
	LinphoneCoreNewSubscriptionRequestedCb new_subscription_requested; /**< Notify about pending presence subscription request */
193 194
	LINPHONE_DEPRECATED LinphoneCoreAuthInfoRequestedCb auth_info_requested; /** @brief Ask the application some authentication information.
	                                                                             @deprecated Use authentication_requested instead. Deprecated since 2016-09-21 */
195
	LinphoneCoreAuthenticationRequestedCb authentication_requested; /**< Ask the application some authentication information */
196
	LinphoneCoreCallLogUpdatedCb call_log_updated; /**< Notifies that call log list has been updated */
197
	LinphoneCoreMessageReceivedCb message_received; /**< a message is received, can be text or external body*/
198
	LinphoneCoreCbsMessageReceivedUnableDecryptCb message_received_unable_decrypt; /**< an encrypted message is received but we can't decrypt it*/
199
	LinphoneCoreIsComposingReceivedCb is_composing_received; /**< An is-composing notification has been received */
200 201 202 203 204 205 206 207
	LinphoneCoreDtmfReceivedCb dtmf_received; /**< A dtmf has been received received */
	LinphoneCoreReferReceivedCb refer_received; /**< An out of call refer was received */
	LinphoneCoreCallEncryptionChangedCb call_encryption_changed; /**<Notifies on change in the encryption of call streams */
	LinphoneCoreTransferStateChangedCb transfer_state_changed; /**<Notifies when a transfer is in progress */
	LinphoneCoreBuddyInfoUpdatedCb buddy_info_updated; /**< a LinphoneFriend's BuddyInfo has changed*/
	LinphoneCoreCallStatsUpdatedCb call_stats_updated; /**<Notifies on refreshing of call's statistics. */
	LinphoneCoreInfoReceivedCb info_received; /**<Notifies an incoming informational message received.*/
	LinphoneCoreSubscriptionStateChangedCb subscription_state_changed; /**<Notifies subscription state change */
208
	LinphoneCoreNotifyReceivedCb notify_received; /**< Notifies a an event notification, see linphone_core_subscribe() */
209
	LinphoneCoreSubscribeReceivedCb subscribe_received; /**< Notifies a subscribe has been received, see linphone_core_subscribe() */
210
	LinphoneCorePublishStateChangedCb publish_state_changed;/**Notifies publish state change (only from #LinphoneEvent api)*/
211
	LinphoneCoreConfiguringStatusCb configuring_status; /** Notifies configuring status changes */
212 213 214 215 216 217 218 219
	LINPHONE_DEPRECATED LinphoneCoreTextMessageReceivedCb text_received; /**< @brief A text message has been received.
	                                                                          @deprecated Use #message_received instead. Deprecated since 2015-11-19.  */
	LINPHONE_DEPRECATED LinphoneCoreFileTransferRecvCb file_transfer_recv; /**< @brief Callback to store file received attached to a #LinphoneChatMessage.
	                                                                            @deprecated Deprecated since 2015-11-19. */
	LINPHONE_DEPRECATED LinphoneCoreFileTransferSendCb file_transfer_send; /**< @brief Callback to collect file chunk to be sent for a #LinphoneChatMessage.
	                                                                            @deprecated Deprecated since 2015-11-19. */
	LINPHONE_DEPRECATED LinphoneCoreFileTransferProgressIndicationCb file_transfer_progress_indication; /**< @brief Callback to indicate file transfer progress.
	                                                                                                         @deprecated Deprecated since 2015-11-19. */
220 221 222
	LinphoneCoreNetworkReachableCb network_reachable; /**< Callback to report IP network status (I.E up/down )*/
	LinphoneCoreLogCollectionUploadStateChangedCb log_collection_upload_state_changed; /**< Callback to upload collected logs */
	LinphoneCoreLogCollectionUploadProgressIndicationCb log_collection_upload_progress_indication; /**< Callback to indicate log collection upload progress */
223 224
	LinphoneCoreFriendListCreatedCb friend_list_created;
	LinphoneCoreFriendListRemovedCb friend_list_removed;
225
	LinphoneCoreCbsCallCreatedCb call_created;
Ghislain MARY's avatar
Ghislain MARY committed
226
	LinphoneCoreCbsVersionUpdateCheckResultReceivedCb version_update_check_result_received;
227
	LinphoneCoreCbsChatRoomStateChangedCb chat_room_state_changed;
228
	LinphoneCoreCbsQrcodeFoundCb qrcode_found;
229 230 231
	LinphoneCoreCbsEcCalibrationResultCb ec_calibration_result;
	LinphoneCoreCbsEcCalibrationAudioInitCb ec_calibration_audio_init;
	LinphoneCoreCbsEcCalibrationAudioUninitCb ec_calibration_audio_uninit;
232 233
	LinphoneCoreCbsMessageReceivedCb message_sent;
	LinphoneCoreCbsChatRoomReadCb chat_room_read;
Simon Morlat's avatar
Simon Morlat committed
234
	void *user_data; /**<User data associated with the above callbacks */
aymeric's avatar
aymeric committed
235 236
} LinphoneCoreVTable;

237
/**
238 239 240
 * @brief Instantiate a vtable with all arguments set to NULL.
 * @return newly allocated vtable.
 * @donotwrap
241
 */
242
LINPHONE_PUBLIC LinphoneCoreVTable *linphone_core_v_table_new(void);
243

244
/**
245 246 247 248
 * @brief Sets a user data pointer in the vtable.
 * @param table the vtable.
 * @param data the user data to attach.
 * @donotwrap
249 250 251 252
 */
LINPHONE_PUBLIC void linphone_core_v_table_set_user_data(LinphoneCoreVTable *table, void *data);

/**
253 254 255 256
 * @brief Gets a user data pointer in the vtable.
 * @param table the vtable.
 * @return the data attached to the vtable.
 * @donotwrap
257
 */
258
LINPHONE_PUBLIC void* linphone_core_v_table_get_user_data(const LinphoneCoreVTable *table);
259 260 261 262 263

/**
 * Gets the current VTable.
 * This is meant only to be called from a callback to be able to get the user_data associated with the vtable that called the callback.
 * @param lc the linphonecore
264
 * @return the vtable that called the last callback
265
 * @donotwrap
266 267 268
 */
LINPHONE_PUBLIC LinphoneCoreVTable *linphone_core_get_current_vtable(LinphoneCore *lc);

269
/**
270 271 272
 * @brief Destroy a vtable.
 * @param table to be destroyed.
 * @donotwrap
273
 */
274
LINPHONE_PUBLIC void linphone_core_v_table_destroy(LinphoneCoreVTable* table);
275

276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293
/**
 * Increment the reference counter.
 */
LINPHONE_PUBLIC LinphoneCoreCbs *linphone_core_cbs_ref(LinphoneCoreCbs *cbs);

/**
 * Decrement the reference counter.
 */
LINPHONE_PUBLIC void linphone_core_cbs_unref(LinphoneCoreCbs *cbs);

/**
 * Set private data to be get from each callbacks.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_user_data(LinphoneCoreCbs *cbs, void *user_data);

/**
 * Get the user pointer.
 */
Ghislain MARY's avatar
Ghislain MARY committed
294
LINPHONE_PUBLIC void *linphone_core_cbs_get_user_data(const LinphoneCoreCbs *cbs);
295 296 297 298 299 300 301 302 303

/**
 * 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.
 * @param lc the linphonecore
 * @return the #LinphoneCoreCbs that has called the last callback
 */
LINPHONE_PUBLIC LinphoneCoreCbs *linphone_core_get_current_callbacks(const LinphoneCore *lc);

304 305 306 307 308
/**
 * Set the #LinphoneCoreGlobalStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
309
LINPHONE_PUBLIC void linphone_core_cbs_set_global_state_changed(LinphoneCoreCbs *cbs, LinphoneCoreCbsGlobalStateChangedCb cb);
310

311 312 313 314 315 316 317
/**
 * Get the # callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsGlobalStateChangedCb linphone_core_cbs_get_global_state_changed(LinphoneCoreCbs *cbs);

318 319 320 321 322 323 324
/**
 * Set the #LinphoneCoreCbsRegistrationStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_registration_state_changed(LinphoneCoreCbs *cbs, LinphoneCoreCbsRegistrationStateChangedCb cb);

325 326 327 328 329 330 331
/**
 * Get the #LinphoneCoreCbsRegistrationStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsRegistrationStateChangedCb linphone_core_cbs_get_registration_state_changed(LinphoneCoreCbs *cbs);

332 333 334 335 336 337 338
/**
 * Set the #LinphoneCoreCbsCallStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_call_state_changed(LinphoneCoreCbs *cbs, LinphoneCoreCbsCallStateChangedCb cb);

339 340 341 342 343 344 345
/**
 * Get the #LinphoneCoreCbsCallStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsCallStateChangedCb linphone_core_cbs_get_call_state_changed(LinphoneCoreCbs *cbs);

346 347 348 349 350 351 352
/**
 * Set the #LinphoneCoreCbsNotifyPresenceReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_notify_presence_received(LinphoneCoreCbs *cbs, LinphoneCoreCbsNotifyPresenceReceivedCb cb);

353 354 355 356 357 358 359
/**
 * Get the #LinphoneCoreCbsNotifyPresenceReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsNotifyPresenceReceivedCb linphone_core_cbs_get_notify_presence_received(LinphoneCoreCbs *cbs);

360 361 362 363 364 365 366
/**
 * Set the #LinphoneCoreCbsNotifyPresenceReceivedForUriOrTelCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_notify_presence_received_for_uri_or_tel(LinphoneCoreCbs *cbs, LinphoneCoreCbsNotifyPresenceReceivedForUriOrTelCb cb);

367 368 369 370 371 372 373
/**
 * Get the #LinphoneCoreCbsNotifyPresenceReceivedForUriOrTelCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsNotifyPresenceReceivedForUriOrTelCb linphone_core_cbs_get_notify_presence_received_for_uri_or_tel(LinphoneCoreCbs *cbs);

374 375 376 377 378 379 380
/**
 * Set the #LinphoneCoreCbsNewSubscriptionRequestedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_new_subscription_requested(LinphoneCoreCbs *cbs, LinphoneCoreCbsNewSubscriptionRequestedCb cb);

381 382 383 384 385 386 387
/**
 * Get the #LinphoneCoreCbsNewSubscriptionRequestedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsNewSubscriptionRequestedCb linphone_core_cbs_get_new_subscription_requested(LinphoneCoreCbs *cbs);

388 389 390 391 392 393 394
/**
 * Set the #LinphoneCoreCbsAuthenticationRequestedCb callback.'
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_authentication_requested(LinphoneCoreCbs *cbs, LinphoneCoreCbsAuthenticationRequestedCb cb);

395 396 397 398 399 400 401
/**
 * Get the #LinphoneCoreCbsAuthenticationRequestedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsAuthenticationRequestedCb linphone_core_cbs_get_authentication_requested(LinphoneCoreCbs *cbs);

402 403 404 405 406 407 408
/**
 * Set the #LinphoneCoreCbsCallLogUpdatedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_call_log_updated(LinphoneCoreCbs *cbs, LinphoneCoreCbsCallLogUpdatedCb cb);

409 410 411 412 413 414 415
/**
 * Get the #LinphoneCoreCbsCallLogUpdatedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsCallLogUpdatedCb linphone_core_cbs_get_call_log_updated(LinphoneCoreCbs *cbs);

416 417 418 419 420 421 422
/**
 * Set the #LinphoneCoreCbsMessageReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_message_received(LinphoneCoreCbs *cbs, LinphoneCoreCbsMessageReceivedCb cb);

423 424 425 426 427 428 429
/**
 * Get the #LinphoneCoreCbsMessageReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsMessageReceivedCb linphone_core_cbs_get_message_received(LinphoneCoreCbs *cbs);

430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457
/**
 * Set the #LinphoneCoreCbsMessageSentCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_message_sent(LinphoneCoreCbs *cbs, LinphoneCoreCbsMessageSentCb cb);

/**
 * Get the #LinphoneCoreCbsMessageSentCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsMessageSentCb linphone_core_cbs_get_message_sent(LinphoneCoreCbs *cbs);

/**
 * Set the #LinphoneCoreCbsChatRoomReadCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_chat_room_read(LinphoneCoreCbs *cbs, LinphoneCoreCbsChatRoomReadCb cb);

/**
 * Get the #LinphoneCoreCbsChatRoomReadCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsChatRoomReadCb linphone_core_cbs_get_chat_room_read(LinphoneCoreCbs *cbs);

458 459 460 461 462 463 464 465 466 467 468 469 470 471
/**
 * Set the #LinphoneCoreCbsMessageReceivedUnableDecryptCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_message_received_unable_decrypt(LinphoneCoreCbs *cbs, LinphoneCoreCbsMessageReceivedUnableDecryptCb cb);

/**
 * Get the #LinphoneCoreCbsMessageReceivedUnableDecryptCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsMessageReceivedUnableDecryptCb linphone_core_cbs_get_message_received_unable_decrypt(LinphoneCoreCbs *cbs);

472 473 474 475 476 477 478
/**
 * Set the #LinphoneCoreCbsIsComposingReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_is_composing_received(LinphoneCoreCbs *cbs, LinphoneCoreCbsIsComposingReceivedCb cb);

479 480 481 482 483 484 485
/**
 * Get the #LinphoneCoreCbsIsComposingReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsIsComposingReceivedCb linphone_core_cbs_get_is_composing_received(LinphoneCoreCbs *cbs);

486 487 488 489 490 491 492
/**
 * Set the #LinphoneCoreCbsDtmfReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_dtmf_received(LinphoneCoreCbs *cbs, LinphoneCoreCbsDtmfReceivedCb cb);

493 494 495 496 497 498 499
/**
 * Get the #LinphoneCoreCbsDtmfReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsDtmfReceivedCb linphone_core_cbs_get_dtmf_received(LinphoneCoreCbs *cbs);

500 501 502 503 504 505 506
/**
 * Set the #LinphoneCoreCbsReferReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_refer_received(LinphoneCoreCbs *cbs, LinphoneCoreCbsReferReceivedCb cb);

507 508 509 510 511 512 513
/**
 * Get the #LinphoneCoreCbsReferReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsReferReceivedCb linphone_core_cbs_get_refer_received(LinphoneCoreCbs *cbs);

514 515 516 517 518 519 520
/**
 * Set the #LinphoneCoreCbsCallEncryptionChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_call_encryption_changed(LinphoneCoreCbs *cbs, LinphoneCoreCbsCallEncryptionChangedCb cb);

521 522 523 524 525 526 527
/**
 * Get the #LinphoneCoreCbsCallEncryptionChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsCallEncryptionChangedCb linphone_core_cbs_get_call_encryption_changed(LinphoneCoreCbs *cbs);

528 529 530 531 532 533 534
/**
 * Set the #LinphoneCoreCbsTransferStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_transfer_state_changed(LinphoneCoreCbs *cbs, LinphoneCoreCbsTransferStateChangedCb cb);

535 536 537 538 539 540 541
/**
 * Get the #LinphoneCoreCbsTransferStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsTransferStateChangedCb linphone_core_cbs_get_transfer_state_changed(LinphoneCoreCbs *cbs);

542 543 544 545 546 547 548
/**
 * Set the #LinphoneCoreCbsBuddyInfoUpdatedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_buddy_info_updated(LinphoneCoreCbs *cbs, LinphoneCoreCbsBuddyInfoUpdatedCb cb);

549 550 551 552 553 554 555
/**
 * Get the #LinphoneCoreCbsBuddyInfoUpdatedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsBuddyInfoUpdatedCb linphone_core_cbs_get_buddy_info_updated(LinphoneCoreCbs *cbs);

556 557 558 559 560 561 562
/**
 * Set the #LinphoneCoreCbsCallStatsUpdatedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_call_stats_updated(LinphoneCoreCbs *cbs, LinphoneCoreCbsCallStatsUpdatedCb cb);

563 564 565 566 567 568 569
/**
 * Get the #LinphoneCoreCbsCallStatsUpdatedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsCallStatsUpdatedCb linphone_core_cbs_get_call_stats_updated(LinphoneCoreCbs *cbs);

570 571 572 573 574 575 576
/**
 * Set the #LinphoneCoreCbsInfoReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_info_received(LinphoneCoreCbs *cbs, LinphoneCoreCbsInfoReceivedCb cb);

577 578 579 580 581 582 583
/**
 * Get the #LinphoneCoreCbsInfoReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsInfoReceivedCb linphone_core_cbs_get_info_received(LinphoneCoreCbs *cbs);

584 585 586 587 588 589 590
/**
 * Set the #LinphoneCoreCbsSubscriptionStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_subscription_state_changed(LinphoneCoreCbs *cbs, LinphoneCoreCbsSubscriptionStateChangedCb cb);

591 592 593 594 595 596 597
/**
 * Get the #LinphoneCoreCbsSubscriptionStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsSubscriptionStateChangedCb linphone_core_cbs_get_subscription_state_changed(LinphoneCoreCbs *cbs);

598 599 600 601 602 603 604
/**
 * Set the #LinphoneCoreCbsNotifyReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_notify_received(LinphoneCoreCbs *cbs, LinphoneCoreCbsNotifyReceivedCb cb);

605 606 607 608 609 610 611
/**
 * Get the #LinphoneCoreCbsNotifyReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsNotifyReceivedCb linphone_core_cbs_get_notify_received(LinphoneCoreCbs *cbs);

612 613 614 615 616 617 618 619 620 621 622 623 624 625
/**
 * Set the #LinphoneCoreCbsSubscribeReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_subscribe_received(LinphoneCoreCbs *cbs, LinphoneCoreCbsSubscribeReceivedCb cb);

/**
 * Get the #LinphoneCoreCbsSubscribeReceivedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsSubscribeReceivedCb linphone_core_cbs_get_subscribe_received(LinphoneCoreCbs *cbs);

626 627 628 629 630 631 632
/**
 * Set the #LinphoneCoreCbsPublishStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_publish_state_changed(LinphoneCoreCbs *cbs, LinphoneCoreCbsPublishStateChangedCb cb);

633 634 635 636 637 638 639
/**
 * Get the #LinphoneCoreCbsPublishStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsPublishStateChangedCb linphone_core_cbs_get_publish_state_changed(LinphoneCoreCbs *cbs);

640 641 642 643 644 645 646
/**
 * Set the #LinphoneCoreCbsConfiguringStatusCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_configuring_status(LinphoneCoreCbs *cbs, LinphoneCoreCbsConfiguringStatusCb cb);

647 648 649 650 651 652 653
/**
 * Get the #LinphoneCoreCbsConfiguringStatusCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsConfiguringStatusCb linphone_core_cbs_get_configuring_status(LinphoneCoreCbs *cbs);

654 655 656 657 658 659 660
/**
 * Set the #LinphoneCoreCbsNetworkReachableCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_network_reachable(LinphoneCoreCbs *cbs, LinphoneCoreCbsNetworkReachableCb cb);

661 662 663 664 665
/**
 * Get the #LinphoneCoreCbsNetworkReachableCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
Sylvain Berfini's avatar
Sylvain Berfini committed
666
LINPHONE_PUBLIC LinphoneCoreCbsNetworkReachableCb linphone_core_cbs_get_network_reachable(LinphoneCoreCbs *cbs);
667

668 669 670 671 672 673 674
/**
 * Set the #LinphoneCoreCbsLogCollectionUploadStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_log_collection_upload_state_changed(LinphoneCoreCbs *cbs, LinphoneCoreCbsLogCollectionUploadStateChangedCb cb);

675 676 677 678 679 680 681
/**
 * Get the #LinphoneCoreCbsLogCollectionUploadStateChangedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsLogCollectionUploadStateChangedCb linphone_core_cbs_get_log_collection_upload_state_changed(LinphoneCoreCbs *cbs);

682 683 684 685 686 687 688
/**
 * Set the #LinphoneCoreCbsLogCollectionUploadProgressIndicationCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_log_collection_upload_progress_indication(LinphoneCoreCbs *cbs, LinphoneCoreCbsLogCollectionUploadProgressIndicationCb cb);

689 690 691 692 693 694 695
/**
 * Get the #LinphoneCoreCbsLogCollectionUploadProgressIndicationCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsLogCollectionUploadProgressIndicationCb linphone_core_cbs_get_log_collection_upload_progress_indication(LinphoneCoreCbs *cbs);

696 697 698 699 700 701 702
/**
 * Set the #LinphoneCoreCbsFriendListCreatedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_friend_list_created(LinphoneCoreCbs *cbs, LinphoneCoreCbsFriendListCreatedCb cb);

703 704 705 706 707 708 709
/**
 * Get the #LinphoneCoreCbsFriendListCreatedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsFriendListCreatedCb linphone_core_cbs_get_friend_list_created(LinphoneCoreCbs *cbs);

710 711 712 713 714 715 716
/**
 * Set the #LinphoneCoreCbsFriendListRemovedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @param[in] cb The callback.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_friend_list_removed(LinphoneCoreCbs *cbs, LinphoneCoreCbsFriendListRemovedCb cb);

717 718 719 720 721 722 723
/**
 * Get the #LinphoneCoreCbsFriendListRemovedCb callback.
 * @param[in] cbs A #LinphoneCoreCbs.
 * @return The callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsFriendListRemovedCb linphone_core_cbs_get_friend_list_removed(LinphoneCoreCbs *cbs);

724 725
/**
 * Set the call created callback.
726
 * @param[in] cbs #LinphoneCallCbs object.
727 728 729 730 731 732
 * @param[in] cb The call created callback to be used.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_call_created(LinphoneCoreCbs *cbs, LinphoneCoreCbsCallCreatedCb cb);

/**
 * Get the call created callback.
733
 * @param[in] cbs #LinphoneCoreCbs object.
734 735 736 737
 * @return The current call created callback.
 */
LINPHONE_PUBLIC LinphoneCoreCbsCallCreatedCb linphone_core_cbs_get_call_created(LinphoneCoreCbs *cbs);

Ghislain MARY's avatar
Ghislain MARY committed
738 739
/**
 * Set the version update check result callback.
740
 * @param[in] cbs #LinphoneCoreCbs object
Ghislain MARY's avatar
Ghislain MARY committed
741 742 743 744 745 746
 * @param[in] cb The callback to use
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_version_update_check_result_received(LinphoneCoreCbs *cbs, LinphoneCoreCbsVersionUpdateCheckResultReceivedCb cb);

/**
 * Get the version update check result callback.
747
 * @param[in] cbs #LinphoneCoreCbs object
Ghislain MARY's avatar
Ghislain MARY committed
748 749 750 751
 * @return The current callback
 */
LINPHONE_PUBLIC LinphoneCoreCbsVersionUpdateCheckResultReceivedCb linphone_core_cbs_get_version_update_check_result_received(LinphoneCoreCbs *cbs);

752
/**
753
 * Get the chat room state changed callback.
754
 * @param[in] cbs #LinphoneCoreCbs object
755 756
 * @return The current callback
 */
757
LINPHONE_PUBLIC LinphoneCoreCbsChatRoomStateChangedCb linphone_core_cbs_get_chat_room_state_changed (LinphoneCoreCbs *cbs);
758 759

/**
760
 * Set the chat room state changed callback.
761
 * @param[in] cbs #LinphoneCoreCbs object
762 763
 * @param[in] cb The callback to use
 */
764
LINPHONE_PUBLIC void linphone_core_cbs_set_chat_room_state_changed (LinphoneCoreCbs *cbs, LinphoneCoreCbsChatRoomStateChangedCb cb);
765

766
/**
767
 * Get the qrcode found callback.
768 769 770
 * @param[in] cbs LinphoneCoreCbs object
 * @return The current callback
 */
771
LINPHONE_PUBLIC LinphoneCoreCbsQrcodeFoundCb linphone_core_cbs_get_qrcode_found(LinphoneCoreCbs *cbs);
772 773 774 775 776 777

/**
 * Set the qrcode found callback.
 * @param[in] cbs LinphoneCoreCbs object
 * @param[in] cb The callback to use
 **/
778
LINPHONE_PUBLIC void linphone_core_cbs_set_qrcode_found(LinphoneCoreCbs *cbs, LinphoneCoreCbsQrcodeFoundCb cb);
779

780 781 782 783 784 785 786 787 788 789 790 791 792 793 794
/**
 * @brief Sets a callback to call each time the echo-canceler calibration is completed.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_ec_calibration_result(LinphoneCoreCbs *cbs, LinphoneCoreCbsEcCalibrationResultCb cb);

/**
 * @brief Sets a callback to call when the echo-canceler calibrator has completed its audio graph.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_ec_calibration_audio_init(LinphoneCoreCbs *cbs, LinphoneCoreCbsEcCalibrationAudioInitCb cb);

/**
 * @brief Sets a callback to call when the echo-canceler calibrator destroys its audio graph.
 */
LINPHONE_PUBLIC void linphone_core_cbs_set_ec_calibration_audio_uninit(LinphoneCoreCbs *cbs, LinphoneCoreCbsEcCalibrationAudioUninitCb cb);

smorlat's avatar
smorlat committed
795 796 797 798
/**
 * @}
**/

799
typedef void * (*LinphoneCoreWaitingCallback)(LinphoneCore *lc, void *context, LinphoneWaitingState ws, const char *purpose, float progress);
800

aymeric's avatar
aymeric committed
801

802 803 804 805 806
/**
 * @addtogroup initializing
 * @{
**/

807 808
/**
 * Tells whether the linphone core log collection is enabled.
809
 * @return The state of the linphone core log collection.
810 811 812
 */
LINPHONE_PUBLIC LinphoneLogCollectionState linphone_core_log_collection_enabled(void);

813 814
/**
 * Enable the linphone core log collection to upload logs on a server.
815
 * @param[in] state #LinphoneLogCollectionState value telling whether to enable log collection or not.
816
 */
817
LINPHONE_PUBLIC void linphone_core_enable_log_collection(LinphoneLogCollectionState state);
818

819 820
/**
 * Get the path where the log files will be written for log collection.
821
 * @return The path where the log files will be written.
822 823 824
 */
LINPHONE_PUBLIC const char * linphone_core_get_log_collection_path(void);

825
/**
826
 * Set the path of a directory where the log files will be written for log collection.
827 828 829 830
 * @param[in] path The path where the log files will be written.
 */
LINPHONE_PUBLIC void linphone_core_set_log_collection_path(const char *path);

831 832
/**
 * Get the prefix of the filenames that will be used for log collection.
833
 * @return The prefix of the filenames used for log collection.
834 835 836 837 838 839 840 841 842 843 844
 */
LINPHONE_PUBLIC const char * linphone_core_get_log_collection_prefix(void);

/**
 * Set the prefix of the filenames that will be used for log collection.
 * @param[in] prefix The prefix to use for the filenames for log collection.
 */
LINPHONE_PUBLIC void linphone_core_set_log_collection_prefix(const char *prefix);

/**
 * Get the max file size in bytes of the files used for log collection.
845
 * @return The max file size in bytes of the files used for log collection.
846
 */
847
LINPHONE_PUBLIC size_t linphone_core_get_log_collection_max_file_size(void);
848 849 850

/**
 * Set the max file size in bytes of the files used for log collection.
851 852 853 854
 * Warning: this function should only not be used to change size
 * dynamically but instead only before calling @see
 * linphone_core_enable_log_collection. If you increase max size
  * on runtime, logs chronological order COULD be broken.
855 856
 * @param[in] size The max file size in bytes of the files used for log collection.
 */
857
LINPHONE_PUBLIC void linphone_core_set_log_collection_max_file_size(size_t size);
858

859 860
/**
 * Set the url of the server where to upload the collected log files.
861
 * @param[in] core #LinphoneCore object
862 863 864 865
 * @param[in] server_url The url of the server where to upload the collected log files.
 */
LINPHONE_PUBLIC void linphone_core_set_log_collection_upload_server_url(LinphoneCore *core, const char *server_url);

866 867
/**
 * Gets the url of the server where to upload the collected log files.
868
 * @param[in] core #LinphoneCore object
869 870 871 872
 * @return The url of the server where to upload the collected log files.
 */
LINPHONE_PUBLIC const char * linphone_core_get_log_collection_upload_server_url(LinphoneCore *core);

873 874
/**
 * Upload the log collection to the configured server url.
875
 * @param[in] core #LinphoneCore object
876 877 878
 */
LINPHONE_PUBLIC void linphone_core_upload_log_collection(LinphoneCore *core);

879 880 881 882
/**
 * Compress the log collection in a single file.
 * @return The path of the compressed log collection file (to be freed calling ms_free()).
 */
883
LINPHONE_PUBLIC char * linphone_core_compress_log_collection(void);
884

885 886 887
/**
 * Reset the log collection by removing the log files.
 */
888
LINPHONE_PUBLIC void linphone_core_reset_log_collection(void);
889

890
/**
891
 * @brief Define a log handler.
892
 * @param logfunc The function pointer of the log handler.
893
 * @deprecated Use #linphone_logging_service_cbs_set_log_message_written() instead. Deprecated since 2017-10-10.
894
 * @donotwrap
895
 */
896
LINPHONE_PUBLIC LINPHONE_DEPRECATED void linphone_core_set_log_handler(OrtpLogFunc logfunc);
897

898
/**
899
 * @brief Define a log file.
900 901 902
 *
 * If the file pointer passed as an argument is NULL, stdout is used instead.
 * @param file A pointer to the FILE structure of the file to write to.
903
 * @deprecated Use #linphone_log_service_set_file() instead. Deprecated since 2017-10-10.
904
 * @donotwrap
905
 */
906
LINPHONE_PUBLIC LINPHONE_DEPRECATED void linphone_core_set_log_file(FILE *file);
907 908

/**
909
 * @brief Define the minimum level for logging.
910
 * @param loglevel Minimum level for logging messages.
911
 * @deprecated Use #linphone_logging_service_set_log_level() instead. Deprecated since 2017-10-10.
912
 * @donotwrap
913
**/
914
LINPHONE_PUBLIC LINPHONE_DEPRECATED void linphone_core_set_log_level(OrtpLogLevel loglevel);
915

916
/**
917
 * Define the log level using mask.
918 919 920 921
 *
 * The loglevel parameter is a bitmask parameter. Therefore to enable only warning and error
 * messages, use ORTP_WARNING | ORTP_ERROR. To disable logs, simply set loglevel to 0.
 *
922 923
 * @param mask A bitmask of the log levels to set.
 * @deprecated Use #linphone_logging_service_set_log_level() instead. Deprecated since 2017-10-10.
924
 */
925
LINPHONE_PUBLIC LINPHONE_DEPRECATED void linphone_core_set_log_level_mask(unsigned int mask);
926

927 928 929 930 931
/**
 * Get defined log level mask.
 *
 * @return The loglevel parameter is a bitmask parameter. Therefore to enable only warning and error
 * messages, use ORTP_WARNING | ORTP_ERROR. To disable logs, simply set loglevel to 0.
932
 * @deprecated Use #linphone_logging_service_get_log_level_mask() instead. Deprecated since 2017-10-10.
933
 */
934
LINPHONE_PUBLIC LINPHONE_DEPRECATED unsigned int linphone_core_get_log_level_mask(void);
935

936 937 938
/**
 * Enable logs in supplied FILE*.
 * @param file a C FILE* where to fprintf logs. If null stdout is used.
939 940
 * @deprecated Use #linphone_core_set_log_file and #linphone_core_set_log_level() instead.
 * Deprecated since 2017-01-12.
941
 * @donotwrap
942
**/
943
LINPHONE_DEPRECATED LINPHONE_PUBLIC void linphone_core_enable_logs(FILE *file);
944 945 946 947 948

/**
 * Enable logs through the user's supplied log callback.
 * @param logfunc The address of a OrtpLogFunc callback whose protoype is
 *            	  typedef void (*OrtpLogFunc)(OrtpLogLevel lev, const char *fmt, va_list args);
949
 * @deprecated Use #linphone_core_set_log_handler and #linphone_core_set_log_level instead.
950
 * Deprecated since 2017-01-12.
951
 * @donotwrap
952
**/
953
LINPHONE_DEPRECATED LINPHONE_PUBLIC void linphone_core_enable_logs_with_cb(OrtpLogFunc logfunc);
954 955 956

/**
 * Entirely disable logging.
957
 * @deprecated Use #linphone_core_set_log_level() instead. Deprecated since 2017-01-12.
958
 * @donotwrap
959
**/
960
LINPHONE_DEPRECATED LINPHONE_PUBLIC void linphone_core_disable_logs(void);
961 962 963 964 965 966 967

/**
 * Enable logs serialization (output logs from either the thread that creates the linphone core or the thread that calls linphone_core_iterate()).
 * Must be called before creating the linphone core.
 */
LINPHONE_PUBLIC void linphone_core_serialize_logs(void);

968 969 970
/**
 * Returns liblinphone's version as a string.
**/
971
LINPHONE_PUBLIC const char *linphone_core_get_version(void);
972 973 974 975

/**
 * @return liblinphone's user agent as a string.
**/
976
LINPHONE_PUBLIC const char *linphone_core_get_user_agent(LinphoneCore *lc);
977

978
/**
979 980
 * @deprecated Use #linphone_core_get_user_agent() instead.
 * Deprecated since 2015-11-19.
981
 * @donotwrap
982
**/
983
LINPHONE_PUBLIC LINPHONE_DEPRECATED const char *linphone_core_get_user_agent_name(void);
984

985
/**
986 987
 * @deprecated Use #linphone_core_get_user_agent instead.
 * Deprecated since 2015-11-19.
988
 * @donotwrap
989
**/
990
LINPHONE_PUBLIC LINPHONE_DEPRECATED const char *linphone_core_get_user_agent_version(void);
aymeric's avatar
aymeric committed
991

992 993 994 995
/**
 * @}
**/

996
/**
997
 * Instanciates a #LinphoneCore object.
998 999
 * @ingroup initializing
 *
1000
 * The #LinphoneCore object is the primary handle for doing all phone actions.
1001
 * It should be unique within your application.
1002
 * @param vtable a #LinphoneCoreVTable structure holding your application callbacks
1003 1004
 * @param config_path a path to a config file. If it does not exists it will be created.
 *        The config file is used to store all settings, call logs, friends, proxies... so that all these settings
1005 1006
 *        become persistent over the life of the LinphoneCore object.
 *        It is allowed to set a NULL config file. In that case LinphoneCore will not store any settings.
1007 1008 1009 1010 1011 1012 1013
 * @param factory_config_path a path to a read-only config file that can be used to
 *        to store hard-coded preference such as proxy settings or internal preferences.
 *        The settings in this factory file always override the one in the normal config file.
 *        It is OPTIONAL, use NULL if unneeded.
 * @param userdata an opaque user pointer that can be retrieved at any time (for example in
 *        callbacks) using linphone_core_get_user_data().
 * @see linphone_core_new_with_config
1014
 * @deprecated Use #linphone_factory_create_core() instead. Deprecated since 2017-01-12.
1015
 * @donotwrap
1016
**/
1017
LINPHONE_DEPRECATED LINPHONE_PUBLIC LinphoneCore *linphone_core_new(const LinphoneCoreVTable *vtable,
1018
						const char *config_path, const char *factory_config_path, void* userdata);
aymeric's avatar
aymeric committed
1019

1020
/**
1021
 * Instantiates a #LinphoneCore object with a given LpConfig.
1022 1023
 * @ingroup initializing
 *
1024
 * The #LinphoneCore object is the primary handle for doing all phone actions.
1025
 * It should be unique within your application.
1026 1027
 * @param vtable a #LinphoneCoreVTable structure holding your application callbacks
 * @param config a pointer to an LpConfig object holding the configuration of the #LinphoneCore to be instantiated.
1028 1029 1030
 * @param userdata an opaque user pointer that can be retrieved at any time (for example in
 *        callbacks) using linphone_core_get_user_data().
 * @see linphone_core_new
1031
 * @deprecated Use #linphone_factory_create_core_with_config() instead. Deprecated since 2017-01-12.
1032
 * @donotwrap
1033
**/
1034 1035
LINPHONE_DEPRECATED LINPHONE_PUBLIC LinphoneCore *linphone_core_new_with_config(const LinphoneCoreVTable *vtable, LpConfig *config, void *userdata);

1036
/**
1037 1038 1039
 * Start a #LinphoneCore object after it has been instantiated and not automatically started.
 * Also re-initialize a #LinphoneCore object that has been stopped using linphone_core_stop().
 * Must be called only if #LinphoneGlobalState is either Ready of Off. State will changed to Startup, Configuring and then On.
1040 1041
 * @ingroup initializing
 * @param[in] core The #LinphoneCore object to be started
1042
 * @return 0: success, -1: global failure, -2: could not connect database
1043
 */
1044
LINPHONE_PUBLIC LinphoneStatus linphone_core_start(LinphoneCore *lc);
1045

1046 1047 1048 1049 1050 1051 1052 1053 1054
/**
 * Stop a #LinphoneCore object after it has been instantiated and started.
 * If stopped, it can be started again using linphone_core_start().
 * Must be called only if #LinphoneGlobalState is either On. State will changed to Shutdown and then Off.
 * @ingroup initializing
 * @param[in] core The #LinphoneCore object to be stopped
 */
LINPHONE_PUBLIC void linphone_core_stop (LinphoneCore *core);

1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069
/**
 * Increment the reference counter of a #LinphoneCore object.
 * @param lc The #LinphoneCore which the ref counter is to be incremented.
 * @return A pointer on the #LinphoneCore passed as parameter.
 * @ingroup initializing
 */
LINPHONE_PUBLIC LinphoneCore *linphone_core_ref(LinphoneCore *lc);

/**
 * Decrement the ref counter of a #LinphoneCore object and destroy it
 * if the counter reach 0.
 * @param lc The #LinphoneCore which the reference counter is to be decreased.
 * @ingroup initializing
 */
LINPHONE_PUBLIC void linphone_core_unref(LinphoneCore *lc);
1070

1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082
/**
 * Main loop function. It is crucial that your application call it periodically.
 *
 * linphone_core_iterate() performs various backgrounds tasks:
 * - receiving of SIP messages
 * - handles timers and timeout
 * - performs registration to proxies
 * - authentication retries
 * The application MUST call this function periodically, in its main loop.
 * Be careful that this function must be called from the same thread as
 * other liblinphone methods. If it is not the case make sure all liblinphone calls are
 * serialized with a mutex.
1083
 * For ICE to work properly it should be called every 20ms.
1084
 * @param[in] lc #LinphoneCore object
1085
 * @ingroup initializing
1086 1087
**/
LINPHONE_PUBLIC void linphone_core_iterate(LinphoneCore *lc);
1088

jehan's avatar
jehan committed
1089 1090
/**
 * @ingroup initializing
1091
 * add a listener to be notified of linphone core events. Once events are received, registered vtable are invoked in order.
1092
 * @param vtable a #LinphoneCoreVTable structure holding your application callbacks. Object is owned by linphone core until linphone_core_remove_listener.
jehan's avatar
jehan committed
1093
 * @param lc object
1094
 * @deprecated Use linphone_core_add_callbacks() instead. Deprecated since 2017-01-12.
1095
 * @donotwrap
jehan's avatar
jehan committed
1096
 */
1097
LINPHONE_DEPRECATED LINPHONE_PUBLIC void linphone_core_add_listener(LinphoneCore *lc, LinphoneCoreVTable *vtable);
1098

1099 1100
/**
 * @ingroup initializing
1101 1102
 * Add a listener in order to be notified of #LinphoneCore events. Once an event is received, registred #LinphoneCoreCbs are
 * invoked sequencially.
1103
 * @param lc The #LinphoneCore object to monitor.
1104
 * @param cbs A #LinphoneCoreCbs object holding the callbacks you need. A reference is taken by #LinphoneCore until you invoke linphone_core_remove_callbacks().
1105 1106
 */
LINPHONE_PUBLIC void linphone_core_add_callbacks(LinphoneCore *lc, LinphoneCoreCbs *cbs);
1107

jehan's avatar
jehan committed
1108 1109
/**
 * @ingroup initializing
1110 1111
 * remove a listener registred by linphone_core_add_listener.
 * @param lc object
1112
 * @param vtable a #LinphoneCoreVTable structure holding your application callbacks.
1113
 * @deprecated Use linphone_core_remove_callbacks() instead. Deprecated since 2017-01-12.
1114
 * @donotwrap
jehan's avatar
jehan committed
1115
 */
1116
LINPHONE_DEPRECATED LINPHONE_PUBLIC void linphone_core_remove_listener(LinphoneCore *lc, const LinphoneCoreVTable *vtable);
1117

1118 1119 1120 1121 1122 1123 1124
/**
 * @ingroup initializing
 * Remove a listener from a #LinphoneCore
 * @param lc The #LinphoneCore
 * @param cbs The pointer on the #LinphoneCoreCbs to remove.
 */
LINPHONE_PUBLIC void linphone_core_remove_callbacks(LinphoneCore *lc, const LinphoneCoreCbs *cbs);
jehan's avatar
jehan committed
1125

1126
/**
1127 1128 1129 1130 1131 1132 1133 1134 1135
 * @brief 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 NULL is given to "version".
 * If NULL 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.
 * @param[in] lc The core.
 * @param[in] ua_name Name of the user agent.
 * @param[in] version Version of the user agent.
1136 1137 1138
 * @ingroup misc
**/
LINPHONE_PUBLIC void linphone_core_set_user_agent(LinphoneCore *lc, const char *ua_name, const char *version);
1139

1140 1141 1142 1143 1144
/**
 * See linphone_proxy_config_normalize_sip_uri for documentation. Default proxy config is used to parse
 * the address.
 * @ingroup misc
 */
1145
LINPHONE_PUBLIC LinphoneAddress * linphone_core_interpret_url(LinphoneCore *lc, const char *url);
1146

1147
/**
1148 1149
 * @brief Initiates an outgoing call.
 *
1150 1151
 * 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.
1152
 *
1153 1154
 * @param[in] lc LinphoneCore object
 * @param[in] url The destination of the call (sip address, or phone number).
1155
 * @return A #LinphoneCall object or NULL in case of failure
1156 1157 1158
 * @ingroup call_control
**/
LINPHONE_PUBLIC LinphoneCall * linphone_core_invite(LinphoneCore *lc, const char *url);
aymeric's avatar
aymeric committed
1159

1160
/**
1161 1162
 * Initiates an outgoing call given a destination #LinphoneAddress
 * The #LinphoneAddress can be constructed directly using linphone_address_new(), or
1163
 * created by linphone_core_interpret_url().
1164 1165 1166
 * 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.
 * @param[in] lc #LinphoneCore object
1167
 * @param[in] addr The destination of the call (sip address).
1168
 * @return A #LinphoneCall object or NULL in case of failure
1169 1170 1171
 * @ingroup call_control
**/
LINPHONE_PUBLIC LinphoneCall * linphone_core_invite_address(LinphoneCore *lc, const LinphoneAddress *addr);
1172

1173 1174
/**
 * Initiates an outgoing call according to supplied call parameters
1175 1176 1177
 * 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.
 * @param[in] lc #LinphoneCore object
1178
 * @param[in] url The destination of the call (sip address, or phone number).
1179
 * @param[in] params Call parameters
1180
 * @return A #LinphoneCall object or NULL in case of failure
1181 1182 1183
 * @ingroup call_control
**/
LINPHONE_PUBLIC LinphoneCall * linphone_core_invite_with_params(LinphoneCore *lc, const char *url, const LinphoneCallParams *params);
1184

1185
/**
1186 1187
 * Initiates an outgoing call given a destination #LinphoneAddress
 * The #LinphoneAddress can be constructed directly using linphone_address_new(), or
1188
 * created by linphone_core_interpret_url().
1189 1190 1191
 * 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.
 * @param[in] lc #LinphoneCore object
1192 1193
 * @param[in] addr The destination of the call (sip address).
 * @param[in] params Call parameters
1194
 * @return A #LinphoneCall object or NULL in case of failure
1195
 * @ingroup call_control
1196
**/
1197
LINPHONE_PUBLIC LinphoneCall * linphone_core_invite_address_with_params(LinphoneCore *lc, const LinphoneAddress *addr, const LinphoneCallParams *params);
1198

1199
/**
1200 1201
 * @brief Performs a simple call transfer to the specified destination.
 *
1202 1203 1204 1205 1206
 * The remote endpoint is expected to issue a new call to the specified destination.
 * The current call remains active and thus can be later paused or terminated.
 * It is possible to follow the progress of the transfer provided that transferee sends notification about it.
 * In this case, the transfer_state_changed callback of the #LinphoneCoreVTable is invoked to notify of the state of the new call at the other party.
 * The notified states are #LinphoneCallOutgoingInit , #LinphoneCallOutgoingProgress, #LinphoneCallOutgoingRinging and #LinphoneCallConnected.
1207
 * @param[in] lc #LinphoneCore object
1208 1209 1210 1211
 * @param[in] call The call to be transfered
 * @param[in] refer_to The destination the call is to be refered to
 * @return 0 on success, -1 on failure
 * @ingroup call_control
1212
 * @deprecated Use #linphone_call_transfer() instead. Deprecated since 2017-02-13.
1213
**/
1214
LINPHONE_PUBLIC LINPHONE_DEPRECATED LinphoneStatus linphone_core_transfer_call(LinphoneCore *lc, LinphoneCall *call, const char *refer_to);
aymeric's avatar
aymeric committed
1215

1216
/**
1217 1218
 * @brief Transfers a call to destination of another running call. This is used for "attended transfer" scenarios.
 *
1219 1220 1221 1222 1223 1224 1225 1226
 * The transfered call is supposed to be in paused state, so that it is able to accept the transfer immediately.
 * The destination call is a call previously established to introduce the transfered person.
 * This method will send a transfer request to the transfered person. The phone of the transfered is then
 * expected to automatically call to the destination of the transfer. The receiver of the transfer will then automatically
 * close the call with us (the 'dest' call).
 * It is possible to follow the progress of the transfer provided that transferee sends notification about it.
 * In this case, the transfer_state_changed callback of the #LinphoneCoreVTable is invoked to notify of the state of the new call at the other party.
 * The notified states are #LinphoneCallOutgoingInit , #LinphoneCallOutgoingProgress, #LinphoneCallOutgoingRinging and #LinphoneCallConnected.
1227
 * @param[in] lc #LinphoneCore object
1228 1229 1230 1231
 * @param[in] call A running call you want to transfer
 * @param[in] dest A running call whose remote person will receive the transfer
 * @return 0 on success, -1 on failure
 * @ingroup call_control
1232
 * @deprecated Use #linphone_call_transfer_to_another() instead. Deprecated since 2017-02-13.
1233
**/
1234
LINPHONE_PUBLIC LINPHONE_DEPRECATED LinphoneStatus linphone_core_transfer_call_to_another(LinphoneCore *lc, LinphoneCall *call, LinphoneCall *dest);
1235

1236
/**
1237 1238
 * @brief Start a new call as a consequence of a transfer request received from a call.
 *
1239
 * This function is for advanced usage: the execution of transfers is automatically managed by the LinphoneCore. However if an application
1240
 * wants to have control over the call parameters for the new call, it should call this function immediately during the #LinphoneCallRefered notification.
1241
 * @see LinphoneCoreVTable::call_state_changed
1242 1243
 * @param[in] lc #LinphoneCore object
 * @param[in] call A call that has just been notified about #LinphoneCallRefered state event.
1244
 * @param[in] params The call parameters to be applied to the new call.
1245
 * @return A #LinphoneCall corresponding to the new call that is attempted to the transfer destination.
1246
**/
1247 1248
LINPHONE_PUBLIC LinphoneCall * linphone_core_start_refered_call(LinphoneCore *lc, LinphoneCall *call, const LinphoneCallParams *params);

1249 1250 1251 1252
/** @deprecated Use linphone_core_is_incoming_invite_pending() instead. */
#define linphone_core_inc_invite_pending(lc) linphone_core_is_incoming_invite_pending(lc)

/**
1253 1254
 * @brief Tells whether there is an incoming invite pending.
 *
1255
 * @ingroup call_control
1256
 * @param[in] lc #LinphoneCore object
1257 1258
 * @return A boolean telling whether an incoming invite is pending or not.
 */
1259
LINPHONE_PUBLIC bool_t linphone_core_is_incoming_invite_pending(LinphoneCore*lc);
aymeric's avatar
aymeric committed
1260

1261 1262
/**
 * Tells whether there is a call running.
1263
 * @param[in] lc #LinphoneCore object
1264 1265 1266
 * @return A boolean value telling whether a call is currently running or not
 * @ingroup call_control
**/
1267
LINPHONE_PUBLIC bool_t linphone_core_in_call(const LinphoneCore *lc);
aymeric's avatar
aymeric committed
1268

1269 1270
/**
 * Gets the current call.
1271
 * @param[in] lc #LinphoneCore object
1272 1273 1274 1275
 * @return The current call or NULL if no call is running
 * @ingroup call_control
**/
LINPHONE_PUBLIC LinphoneCall *linphone_core_get_current_call(const LinphoneCore *lc);
1276

1277
/**
1278
 * @brief Accept an incoming call.
1279 1280 1281
 *
 * Basically the application is notified of incoming calls within the
 * call_state_changed callback of the #LinphoneCoreVTable structure, where it will receive
1282
 * a #LinphoneCallIncoming event with the associated #LinphoneCall object.
1283
 * The application can later accept the call using this method.
1284 1285
 * @param[in] lc #LinphoneCore object
 * @param[in] call The #LinphoneCall object representing the call to be answered
1286 1287
 * @return 0 on success, -1 on failure
 * @ingroup call_control
1288
 * @deprecated Use #linphone_call_accept() instead. Deprecated since 2017-02-13.
1289
**/
1290
LINPHONE_PUBLIC LINPHONE_DEPRECATED LinphoneStatus linphone_core_accept_call(LinphoneCore *lc, LinphoneCall *call);
1291

1292
/**
1293
 * @brief Accept an incoming call, with parameters.
1294 1295 1296
 *
 * Basically the application is notified of incoming calls within the
 * call_state_changed callback of the #LinphoneCoreVTable structure, where it will receive
1297
 * a #LinphoneCallIncoming event with the associated #LinphoneCall object.
1298 1299
 * The application can later accept the call using
 * this method.
1300 1301
 * @param[in] lc #LinphoneCore object
 * @param[in] call The #LinphoneCall object representing the call to be answered
1302 1303 1304
 * @param[in] params The specific parameters for this call, for example whether video is accepted or not. Use NULL to use default parameters
 * @return 0 on success, -1 on failure
 * @ingroup call_control
1305
 * @deprecated Use #linphone_call_accept_with_params() instead. Deprecated since 2017-02-13.
1306
**/
1307
LINPHONE_PUBLIC LINPHONE_DEPRECATED LinphoneStatus linphone_core_accept_call_with_params(LinphoneCore *lc, LinphoneCall *call, const LinphoneCallParams *params);
1308

1309
/**
1310 1311
 * @brief When receiving an incoming, accept to start a media session as early-media.
 *
1312 1313 1314
 * This means the call is not accepted but audio & video streams can be established if the remote party supports early media.
 * However, unlike after call acceptance, mic and camera input are not sent during early-media, though received audio & video are played normally.
 * The call can then later be fully accepted using linphone_core_accept_call() or linphone_core_accept_call_with_params().
1315
 * @param[in] lc #LinphoneCore object
1316 1317 1318 1319
 * @param[in] call The call to accept
 * @param[in] params The call parameters to use (can be NULL)
 * @return 0 if successful, -1 otherwise
 * @ingroup call_control
1320
 * @deprecated Use linphone_call_accept_early_media_with_params() instead.
1321
**/
1322
LINPHONE_PUBLIC LINPHONE_DEPRECATED LinphoneStatus linphone_core_accept_early_media_with_params(LinphoneCore* lc, LinphoneCall* call, const LinphoneCallParams* params);
1323

1324
/**
1325 1326
 * @brief Accept an early media session for an incoming call.
 *
1327
 * This is identical as calling linphone_core_accept_early_media_with_params() with NULL call parameters.
1328
 * @param[in] lc #LinphoneCore object
1329 1330 1331 1332
 * @param[in] call The incoming call to accept
 * @return 0 if successful, -1 otherwise
 * @ingroup call_control
 * @see linphone_core_accept_early_media_with_params()
1333
 * @deprecated Use #linphone_call_accept_early_media() instead. Deprecated since 2017-02-13.
1334
**/
1335
LINPHONE_PUBLIC LINPHONE_DEPRECATED LinphoneStatus linphone_core_accept_early_media(LinphoneCore* lc, LinphoneCall* call);
1336

1337
/**
1338 1339
 * @brief Terminates a call.
 *
1340 1341 1342 1343
 * @param[in] lc LinphoneCore object
 * @param[in] call The LinphoneCall object representing the call to be terminated
 * @return 0 on success, -1 on failure
 * @ingroup call_control
1344
 * @deprecated Use #linphone_call_terminate() instead. Deprecated since 2017-02-13.
1345
**/
1346
LINPHONE_PUBLIC LINPHONE_DEPRECATED LinphoneStatus linphone_core_terminate_call(LinphoneCore *lc, LinphoneCall *call);
1347

Ghislain MARY's avatar
Ghislain MARY committed
1348 1349
/**
 * Redirect the specified call to the given redirect URI.
1350 1351 1352
 * @param[in] lc #LinphoneCore object
 * @param[in] call The #LinphoneCall to redirect
 * @param[in] redirect_uri The URI to redirect the call to
1353
 * @return 0 if successful, -1 on error.
Ghislain MARY's avatar
Ghislain MARY committed
1354
 * @ingroup call_control
1355
 * @deprecated Use #linphone_call_redirect() instead. Deprecated since 2017-02-13.
Ghislain MARY's avatar
Ghislain MARY committed
1356
 */
1357
LINPHONE_PUBLIC LINPHONE_DEPRECATED LinphoneStatus linphone_core_redirect_call(LinphoneCore *lc, LinphoneCall *call, const char *redirect_uri);
1358

1359
/**
1360 1361 1362 1363
 * @brief Decline a pending incoming call, with a reason.
 * @param[in] lc #LinphoneCore object
 * @param[in] call The #LinphoneCall to decline, must be in the IncomingReceived state
 * @param[in] reason The reason for rejecting the call: #LinphoneReasonDeclined or #LinphoneReasonBusy
1364 1365
 * @return 0 on success, -1 on failure
 * @ingroup call_control
1366
 * @deprecated Use #linphone_call_decline() instead. Deprecated since 2017-02-13.
1367
**/
1368
LINPHONE_PUBLIC LINPHONE_DEPRECATED LinphoneStatus linphone_core_decline_call(LinphoneCore *lc, LinphoneCall * call, LinphoneReason reason);
Simon Morlat's avatar