-
Andrea Gianarda authored
Liblinphone now supports only two types of tchat: - conference based tchat (objects ClientChatRoom and ServerChatRoom) - minimal one-to-one tchat (object BasicChatRoom). The following tchat objects have been deleted: - ProxyChatRoom - BasicToClientGroupChatRoom - ClientGroupToBasicChatRoom 1. Conference based tchat This type of tchat is always linked ot a conference object: - ClientChatRoom belongs to a ClientConference - ServerChatRoom belongs to a ServerConference Only chat specific functionality such as sending a message and ephemeral capabilities are now handled in the tchat object whereas participant and subject handling is taken care by the conference object. These type of tchat object is no longer stored in the map of tchat held by the core but only in the conference map through the pointer of the conference they belong to Conference parameters have been reworked. Now, common parameters to audio video conferences and tchat...
237d9ed6
private.h 6.34 KiB
/*
* Copyright (c) 2010-2022 Belledonne Communications SARL.
*
* This file is part of Liblinphone
* (see https://gitlab.linphone.org/BC/public/liblinphone).
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 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 Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/*
* 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
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef _PRIVATE_H
#define _PRIVATE_H
#include <memory>
#include "linphone/core.h"
#include "linphone/friend.h"
#include "linphone/friendlist.h"
#include "linphone/tunnel.h"
#if __clang__ || ((__GNUC__ == 4 && __GNUC_MINOR__ >= 6) || __GNUC__ > 4)
#pragma GCC diagnostic push
#endif
#ifdef _MSC_VER
#pragma warning(disable : 4996)
#else
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#endif
#include "linphone/core_utils.h"
#if __clang__ || ((__GNUC__ == 4 && __GNUC_MINOR__ >= 6) || __GNUC__ > 4)
#pragma GCC diagnostic pop
#endif
#include "linphone/api/c-conference.h"
#include "c-wrapper/internal/c-sal.h"
#include "sal/call-op.h"
#include "sal/event-op.h"
#include "sal/message-op.h"
#include "sal/presence-op.h"
#include "sal/register-op.h"
#ifdef __cplusplus
#include "core/platform-helpers/platform-helpers.h"
7172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140
#endif
#include "linphone/player.h"
#include "linphone/ringtoneplayer.h"
#include "linphone/sipsetup.h"
#include "quality_reporting.h"
#include "tester_utils.h"
#include "bctoolbox/map.h"
#include "bctoolbox/port.h"
#include "bctoolbox/vfs.h"
#include "belle-sip/belle-sip.h" /*we need this include for all http operations*/
#include <ctype.h>
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "mediastreamer2/ice.h"
#include "mediastreamer2/mediastream.h"
#include "mediastreamer2/msconference.h"
#ifndef LIBLINPHONE_VERSION
#define LIBLINPHONE_VERSION LINPHONE_VERSION
#endif
#ifdef __ANDROID__
#include <jni.h>
#endif
#ifdef _WIN32
#if defined(__MINGW32__) || !defined(WINAPI_FAMILY_PARTITION) || !defined(WINAPI_PARTITION_DESKTOP)
#define LINPHONE_WINDOWS_DESKTOP 1
#elif defined(WINAPI_FAMILY_PARTITION)
// See bctoolbox/include/port.h for WINAPI_PARTITION checker
#if defined(WINAPI_PARTITION_DESKTOP) && WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)
#define LINPHONE_WINDOWS_DESKTOP 1
#elif defined(WINAPI_PARTITION_PC_APP) && WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_PC_APP)
#define LINPHONE_WINDOWS_DESKTOP 1
#define LINPHONE_WINDOWS_UNIVERSAL 1
#define LINPHONE_WINDOWS_UWP 1
#elif defined(WINAPI_PARTITION_PHONE_APP) && WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_PHONE_APP)
#define LINPHONE_WINDOWS_PHONE 1
#elif defined(WINAPI_PARTITION_APP) && WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_APP)
#define LINPHONE_WINDOWS_UNIVERSAL 1
#endif
#endif
#endif
#ifdef _MSC_VER
#if (_MSC_VER >= 1900)
#define LINPHONE_MSC_VER_GREATER_19
#endif
#endif
#ifdef HAVE_SQLITE
#include <sqlite3.h>
#endif
#include "core_private.h"
#include "private_functions.h"
#include "private_structs.h"
#define STRING_RESET(field) \
if (field) bctbx_free(field); \
(field) = NULL
#define STRING_SET(field, value) \
do { \
if (field) { \
bctbx_free(field); \
field = NULL; \
141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171
}; \
field = bctbx_strdup(value); \
} while (0)
#define STRING_TRANSFER(field, newvalue) \
do { \
if (field) { \
bctbx_free(field); \
field = NULL; \
}; \
field = newvalue; \
} while (0)
#define STRING_IS_NULL(field) (field == NULL || !strcmp(field, ""))
#ifdef __cplusplus
#define getPlatformHelpers(lc) static_cast<LinphonePrivate::PlatformHelpers *>(lc->platform_helper)
#endif
#define HOLD_OFF (0)
#define HOLD_ON (1)
#ifndef NB_MAX_CALLS
#define NB_MAX_CALLS (10)
#endif
#define LINPHONE_MAX_CALL_HISTORY_UNLIMITED (-1)
#ifndef LINPHONE_MAX_CALL_HISTORY_SIZE
#define LINPHONE_MAX_CALL_HISTORY_SIZE LINPHONE_MAX_CALL_HISTORY_UNLIMITED
#endif
#endif /* _PRIVATE_H */