/*
 * 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/>.
 */

#ifndef _MSC_VER
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wunused-parameter"
#endif // _MSC_VER

#ifndef _CHAT_ROOM_PARAMS_HH
#define _CHAT_ROOM_PARAMS_HH

#include <string>
#include "chat_room.hh"
#include "object.hh"




struct _LinphoneChatRoomParams;


namespace linphone {


	/**
	 * @brief Object defining parameters for a @ref ChatRoom. 
	 *
	 * Can be created with Core::createDefaultChatRoomParams(). You can use isValid()
	 * to check if your configuration is valid or not.
	 * If the @ref ChatRoom backend is @ref ChatRoom::Backend::Basic, then no other
	 * parameter is required, but @ref ChatMessage sent and received won't benefit
	 * from all features a @ref ChatRoom::Backend::FlexisipChat can offer like
	 * conversation with multiple participants and a subject, end-to-end encryption,
	 * ephemeral messages, etc... but this type is the only one that can interoperate
	 * with other SIP clients or with non-flexisip SIP proxies. 
	 */
	class ChatRoomParams: public Object {
	
		public:

			LINPHONECXX_PUBLIC ChatRoomParams(void *ptr, bool takeRef=true);
			LINPHONECXX_PUBLIC _LinphoneChatRoomParams *cPtr() {return (_LinphoneChatRoomParams *)mPrivPtr;}

	
		public:
			
		
			/**
			 * @brief Get the backend implementation of the chat room associated with the
			 * given parameters. 
			 *
			 * @return the @ref ChatRoom::Backend 
			 * @deprecated 20/05/2024. Use ChatParams::getBackend() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED linphone::ChatRoom::Backend getBackend() const;
			
			/**
			 * @brief Set the backend implementation of these chat room parameters. 
			 *
			 * @param backend The @ref ChatRoom::Backend enum value 
			 * @deprecated 20/05/2024. Use ChatParams::setBackend() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED void setBackend(linphone::ChatRoom::Backend backend);
			
			/**
			 * @brief Get the encryption implementation of the chat room associated with the
			 * given parameters. 
			 *
			 * @return the @ref ChatRoom::EncryptionBackend 
			 * @deprecated 20/05/2024. Use ChatParams::getEncryptionBackend() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED linphone::ChatRoom::EncryptionBackend getEncryptionBackend() const;
			
			/**
			 * @brief Set the encryption backend implementation of these chat room parameters. 
			 *
			 * @param backend The @ref ChatRoom::EncryptionBackend enum value 
			 * @deprecated 20/05/2024. Use ChatParams::setEncryptionBackend() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED void setEncryptionBackend(linphone::ChatRoom::EncryptionBackend backend);
			
			/**
			 * @brief Get the encryption status of the chat room associated with the given
			 * parameters. 
			 *
			 * @return true if encryption is enabled, false otherwise 
			 * @deprecated 20/05/2024. Use ChatParams::encryptionEnabled() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED bool encryptionEnabled() const;
			
			/**
			 * @brief Enables or disables encryption for the chat room associated with the
			 * given parameters. 
			 *
			 * @param encrypted true to enable encryption, false to disable. 
			 * @deprecated 20/05/2024. Use linphone_conference_params_enable_encryption()
			 * instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED void enableEncryption(bool encrypted);
			
			/**
			 * @brief Get lifetime (in seconds) for all new ephemeral messages in the chat
			 * room. 
			 *
			 * After the message is read, it will be deleted after "time" seconds. @see
			 * linphone_chat_room_params_ephemeral_enabled() 
			 * @return the ephemeral lifetime (in seconds) 
			 * @deprecated 20/05/2024. Use ChatParams::getEphemeralLifetime() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED long getEphemeralLifetime() const;
			
			/**
			 * @brief Set lifetime (in seconds) for all new ephemeral messages in the chat
			 * room. 
			 *
			 * After the message is read, it will be deleted after "time" seconds. @see
			 * linphone_chat_room_params_ephemeral_enabled() 
			 * @param time The ephemeral lifetime, default is disabled (0) 
			 * @deprecated 20/05/2024. Use ChatParams::activateEphemeral() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED void setEphemeralLifetime(long time);
			
			/**
			 * @brief Get the ephemeral message mode of the chat room associated with the
			 * given parameters. 
			 *
			 * @return the ephemeral message mode @ref ChatRoom::EphemeralMode 
			 * @deprecated 20/05/2024. Use ChatParams::getEphemeralMode() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED linphone::ChatRoom::EphemeralMode getEphemeralMode() const;
			
			/**
			 * @brief Enables or disables forcing of ephemeral messages for the chat room
			 * associated with the given parameters. 
			 *
			 * @param mode Ephemeral message mode @ref ChatRoom::EphemeralMode. 
			 * @deprecated 20/05/2024. Use ChatParams::setEphemeralMode() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED void setEphemeralMode(linphone::ChatRoom::EphemeralMode mode);
			
			/**
			 * @brief Get the group chat status of the chat room associated with the given
			 * parameters. 
			 *
			 * @return true if group chat is enabled, false if one-to-one 
			 * @deprecated 20/05/2024. Use ConferenceParams::groupEnabled() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED bool groupEnabled() const;
			
			/**
			 * @brief Enables or disables group chat for the chat room associated with the
			 * given parameters. 
			 *
			 * @param group true to enable group chat, false to disable (resulting in
			 * one-to-one chat room) 
			 * @deprecated 20/05/2024. Use ConferenceParams::enableGroup() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED void enableGroup(bool group);
			
			/**
			 * @brief Returns whether the given parameters are valid or not. 
			 *
			 * @return true if the given parameters are valid, false otherwise 
			 * @deprecated 20/05/2024. Use ConferenceParams::isValid() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED bool isValid() const;
			
			/**
			 * @brief Get the real time text status of the chat room associated with the given
			 * parameters. 
			 *
			 * @return true if real time text is enabled, false otherwise 
			 * @deprecated 20/05/2024. Use ChatParams::rttEnabled() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED bool rttEnabled() const;
			
			/**
			 * @brief Enables or disables real time text for the chat room associated with the
			 * given parameters. 
			 *
			 * @param rtt true to enable real time text, false to disable. 
			 * @deprecated 20/05/2024. Use ChatParams::enableRtt() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED void enableRtt(bool rtt);
			
			/**
			 * @brief Get the subject of the chat room. 
			 *
			 * @return The subject.    
			 * @deprecated 20/05/2024. Use ConferenceParams::getSubject() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED std::string getSubject() const;
			
			/**
			 * @brief Set the subject of the chat room. 
			 *
			 * @param subject The subject to set.    
			 * @deprecated 20/05/2024. Use ConferenceParams::setSubject() instead. 
			 */
			LINPHONECXX_PUBLIC LINPHONECXX_DEPRECATED void setSubject(const std::string & subject);
			
			
	};

};

#endif // _CHAT_ROOM_PARAMS_HH

#ifndef _MSC_VER
#pragma GCC diagnostic pop
#endif // _MSC_VER
