TDLib
Loading...
Searching...
No Matches
newChatPrivacySettings Class Referencefinal

Inherits Object.

Description

Contains privacy settings for chats with non-contacts.

Public Member Functions

 newChatPrivacySettings ()
 newChatPrivacySettings (bool allow_new_chats_from_unknown_users_, int53 incoming_paid_message_star_count_)
void store (TlStorerToString &s, const char *field_name) const final
Public Member Functions inherited from TlObject
TlObject & operator= (const TlObject &)=delete
TlObject & operator= (TlObject &&)=default
virtual void store (TlStorerCalcLength &s) const
virtual void store (TlStorerUnsafe &s) const
 TlObject ()=default
 TlObject (const TlObject &)=delete
 TlObject (TlObject &&)=default
virtual ~TlObject ()=default

Public Attributes

bool allow_new_chats_from_unknown_users_
 True, if non-contacts users are able to write first to the current user. Telegram Premium subscribers are able to write first regardless of this setting.
int53 incoming_paid_message_star_count_
 Number of Telegram Stars that must be paid for every incoming private message by non-contacts; 0-getOption("paid_message_star_count_max"). If positive, then allow_new_chats_from_unknown_users must be true. The current user will receive getOption("paid_message_earnings_per_mille") Telegram Stars for each 1000 Telegram Stars paid for message sending. Can be positive, only if getOption("can_enable_paid_messages") is true.

Static Public Attributes

static const std::int32_t ID = 123716192
 Identifier uniquely determining a type of the object.

Constructor & Destructor Documentation

◆ newChatPrivacySettings() [1/2]

newChatPrivacySettings ( )

Contains privacy settings for chats with non-contacts.

◆ newChatPrivacySettings() [2/2]

newChatPrivacySettings ( bool allow_new_chats_from_unknown_users_,
int53 incoming_paid_message_star_count_ )

Contains privacy settings for chats with non-contacts.

Parameters
[in]allow_new_chats_from_unknown_users_True, if non-contacts users are able to write first to the current user. Telegram Premium subscribers are able to write first regardless of this setting.
[in]incoming_paid_message_star_count_Number of Telegram Stars that must be paid for every incoming private message by non-contacts; 0-getOption("paid_message_star_count_max"). If positive, then allow_new_chats_from_unknown_users must be true. The current user will receive getOption("paid_message_earnings_per_mille") Telegram Stars for each 1000 Telegram Stars paid for message sending. Can be positive, only if getOption("can_enable_paid_messages") is true.

Member Function Documentation

◆ store()

void store ( TlStorerToString & s,
const char * field_name ) const
finalvirtual

Helper function for to_string method. Appends string representation of the object to the storer.

Parameters
[in]sStorer to which object string representation will be appended.
[in]field_nameObject field_name if applicable.

Implements TlObject.


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