TDLib
Loading...
Searching...
No Matches
td::td_api::message Class Referencefinal

Inherits td::td_api::Object.

Public Member Functions

 message ()
 
 message (int53 id_, object_ptr< MessageSender > &&sender_id_, int53 chat_id_, object_ptr< MessageSendingState > &&sending_state_, object_ptr< MessageSchedulingState > &&scheduling_state_, bool is_outgoing_, bool is_pinned_, bool can_be_edited_, bool can_be_forwarded_, bool can_be_saved_, bool can_be_deleted_only_for_self_, bool can_be_deleted_for_all_users_, bool can_get_added_reactions_, bool can_get_statistics_, bool can_get_message_thread_, bool can_get_viewers_, bool can_get_media_timestamp_links_, bool can_report_reactions_, bool has_timestamped_media_, bool is_channel_post_, bool is_topic_message_, bool contains_unread_mention_, int32 date_, int32 edit_date_, object_ptr< messageForwardInfo > &&forward_info_, object_ptr< messageImportInfo > &&import_info_, object_ptr< messageInteractionInfo > &&interaction_info_, array< object_ptr< unreadReaction > > &&unread_reactions_, object_ptr< MessageReplyTo > &&reply_to_, int53 message_thread_id_, object_ptr< MessageSelfDestructType > &&self_destruct_type_, double self_destruct_in_, double auto_delete_in_, int53 via_bot_user_id_, string const &author_signature_, int64 media_album_id_, string const &restriction_reason_, object_ptr< MessageContent > &&content_, object_ptr< ReplyMarkup > &&reply_markup_)
 
std::int32_t get_id () const final
 
void store (TlStorerToString &s, const char *field_name) const final
 
- Public Member Functions inherited from td::TlObject
virtual void store (TlStorerUnsafe &s) const
 
virtual void store (TlStorerCalcLength &s) const
 
 TlObject ()=default
 
 TlObject (const TlObject &)=delete
 
TlObjectoperator= (const TlObject &)=delete
 
 TlObject (TlObject &&)=default
 
TlObjectoperator= (TlObject &&)=default
 
virtual ~TlObject ()=default
 

Public Attributes

int53 id_
 Message identifier; unique for the chat to which the message belongs.
 
object_ptr< MessageSendersender_id_
 Identifier of the sender of the message.
 
int53 chat_id_
 Chat identifier.
 
object_ptr< MessageSendingStatesending_state_
 The sending state of the message; may be null if the message isn't being sent and didn't fail to be sent.
 
object_ptr< MessageSchedulingStatescheduling_state_
 The scheduling state of the message; may be null if the message isn't scheduled.
 
bool is_outgoing_
 True, if the message is outgoing.
 
bool is_pinned_
 True, if the message is pinned.
 
bool can_be_edited_
 True, if the message can be edited. For live location and poll messages this fields shows whether editMessageLiveLocation or stopPoll can be used with this message by the application.
 
bool can_be_forwarded_
 True, if the message can be forwarded.
 
bool can_be_saved_
 True, if content of the message can be saved locally or copied.
 
bool can_be_deleted_only_for_self_
 True, if the message can be deleted only for the current user while other users will continue to see it.
 
bool can_be_deleted_for_all_users_
 True, if the message can be deleted for all users.
 
bool can_get_added_reactions_
 True, if the list of added reactions is available through getMessageAddedReactions.
 
bool can_get_statistics_
 True, if the message statistics are available through getMessageStatistics.
 
bool can_get_message_thread_
 True, if information about the message thread is available through getMessageThread and getMessageThreadHistory.
 
bool can_get_viewers_
 True, if chat members already viewed the message can be received through getMessageViewers.
 
bool can_get_media_timestamp_links_
 True, if media timestamp links can be generated for media timestamp entities in the message text, caption or web page description through getMessageLink.
 
bool can_report_reactions_
 True, if reactions on the message can be reported through reportMessageReactions.
 
bool has_timestamped_media_
 True, if media timestamp entities refers to a media in this message as opposed to a media in the replied message.
 
bool is_channel_post_
 True, if the message is a channel post. All messages to channels are channel posts, all other messages are not channel posts.
 
bool is_topic_message_
 True, if the message is a forum topic message.
 
bool contains_unread_mention_
 True, if the message contains an unread mention for the current user.
 
int32 date_
 Point in time (Unix timestamp) when the message was sent.
 
int32 edit_date_
 Point in time (Unix timestamp) when the message was last edited.
 
object_ptr< messageForwardInfoforward_info_
 Information about the initial message sender; may be null if none or unknown.
 
object_ptr< messageImportInfoimport_info_
 Information about the initial message for messages created with importMessages; may be null if the message isn't imported.
 
object_ptr< messageInteractionInfointeraction_info_
 Information about interactions with the message; may be null if none.
 
array< object_ptr< unreadReaction > > unread_reactions_
 Information about unread reactions added to the message.
 
object_ptr< MessageReplyToreply_to_
 Information about the message or the story this message is replying to; may be null if none.
 
int53 message_thread_id_
 If non-zero, the identifier of the message thread the message belongs to; unique within the chat to which the message belongs.
 
object_ptr< MessageSelfDestructTypeself_destruct_type_
 The message's self-destruct type; may be null if none.
 
double self_destruct_in_
 Time left before the message self-destruct timer expires, in seconds; 0 if self-destruction isn't scheduled yet.
 
double auto_delete_in_
 Time left before the message will be automatically deleted by message_auto_delete_time setting of the chat, in seconds; 0 if never.
 
int53 via_bot_user_id_
 If non-zero, the user identifier of the bot through which this message was sent.
 
string author_signature_
 For channel posts and anonymous group messages, optional author signature.
 
int64 media_album_id_
 Unique identifier of an album this message belongs to. Only audios, documents, photos and videos can be grouped together in albums.
 
string restriction_reason_
 If non-empty, contains a human-readable description of the reason why access to this message must be restricted.
 
object_ptr< MessageContentcontent_
 Content of the message.
 
object_ptr< ReplyMarkupreply_markup_
 Reply markup for the message; may be null if none.
 

Static Public Attributes

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

Detailed Description

Describes a message.

Constructor & Destructor Documentation

◆ message() [1/2]

td::td_api::message::message ( )

Describes a message.

◆ message() [2/2]

td::td_api::message::message ( int53  id_,
object_ptr< MessageSender > &&  sender_id_,
int53  chat_id_,
object_ptr< MessageSendingState > &&  sending_state_,
object_ptr< MessageSchedulingState > &&  scheduling_state_,
bool  is_outgoing_,
bool  is_pinned_,
bool  can_be_edited_,
bool  can_be_forwarded_,
bool  can_be_saved_,
bool  can_be_deleted_only_for_self_,
bool  can_be_deleted_for_all_users_,
bool  can_get_added_reactions_,
bool  can_get_statistics_,
bool  can_get_message_thread_,
bool  can_get_viewers_,
bool  can_get_media_timestamp_links_,
bool  can_report_reactions_,
bool  has_timestamped_media_,
bool  is_channel_post_,
bool  is_topic_message_,
bool  contains_unread_mention_,
int32  date_,
int32  edit_date_,
object_ptr< messageForwardInfo > &&  forward_info_,
object_ptr< messageImportInfo > &&  import_info_,
object_ptr< messageInteractionInfo > &&  interaction_info_,
array< object_ptr< unreadReaction > > &&  unread_reactions_,
object_ptr< MessageReplyTo > &&  reply_to_,
int53  message_thread_id_,
object_ptr< MessageSelfDestructType > &&  self_destruct_type_,
double  self_destruct_in_,
double  auto_delete_in_,
int53  via_bot_user_id_,
string const &  author_signature_,
int64  media_album_id_,
string const &  restriction_reason_,
object_ptr< MessageContent > &&  content_,
object_ptr< ReplyMarkup > &&  reply_markup_ 
)

Describes a message.

Parameters
[in]id_Message identifier; unique for the chat to which the message belongs.
[in]sender_id_Identifier of the sender of the message.
[in]chat_id_Chat identifier.
[in]sending_state_The sending state of the message; may be null if the message isn't being sent and didn't fail to be sent.
[in]scheduling_state_The scheduling state of the message; may be null if the message isn't scheduled.
[in]is_outgoing_True, if the message is outgoing.
[in]is_pinned_True, if the message is pinned.
[in]can_be_edited_True, if the message can be edited. For live location and poll messages this fields shows whether editMessageLiveLocation or stopPoll can be used with this message by the application.
[in]can_be_forwarded_True, if the message can be forwarded.
[in]can_be_saved_True, if content of the message can be saved locally or copied.
[in]can_be_deleted_only_for_self_True, if the message can be deleted only for the current user while other users will continue to see it.
[in]can_be_deleted_for_all_users_True, if the message can be deleted for all users.
[in]can_get_added_reactions_True, if the list of added reactions is available through getMessageAddedReactions.
[in]can_get_statistics_True, if the message statistics are available through getMessageStatistics.
[in]can_get_message_thread_True, if information about the message thread is available through getMessageThread and getMessageThreadHistory.
[in]can_get_viewers_True, if chat members already viewed the message can be received through getMessageViewers.
[in]can_get_media_timestamp_links_True, if media timestamp links can be generated for media timestamp entities in the message text, caption or web page description through getMessageLink.
[in]can_report_reactions_True, if reactions on the message can be reported through reportMessageReactions.
[in]has_timestamped_media_True, if media timestamp entities refers to a media in this message as opposed to a media in the replied message.
[in]is_channel_post_True, if the message is a channel post. All messages to channels are channel posts, all other messages are not channel posts.
[in]is_topic_message_True, if the message is a forum topic message.
[in]contains_unread_mention_True, if the message contains an unread mention for the current user.
[in]date_Point in time (Unix timestamp) when the message was sent.
[in]edit_date_Point in time (Unix timestamp) when the message was last edited.
[in]forward_info_Information about the initial message sender; may be null if none or unknown.
[in]import_info_Information about the initial message for messages created with importMessages; may be null if the message isn't imported.
[in]interaction_info_Information about interactions with the message; may be null if none.
[in]unread_reactions_Information about unread reactions added to the message.
[in]reply_to_Information about the message or the story this message is replying to; may be null if none.
[in]message_thread_id_If non-zero, the identifier of the message thread the message belongs to; unique within the chat to which the message belongs.
[in]self_destruct_type_The message's self-destruct type; may be null if none.
[in]self_destruct_in_Time left before the message self-destruct timer expires, in seconds; 0 if self-destruction isn't scheduled yet.
[in]auto_delete_in_Time left before the message will be automatically deleted by message_auto_delete_time setting of the chat, in seconds; 0 if never.
[in]via_bot_user_id_If non-zero, the user identifier of the bot through which this message was sent.
[in]author_signature_For channel posts and anonymous group messages, optional author signature.
[in]media_album_id_Unique identifier of an album this message belongs to. Only audios, documents, photos and videos can be grouped together in albums.
[in]restriction_reason_If non-empty, contains a human-readable description of the reason why access to this message must be restricted.
[in]content_Content of the message.
[in]reply_markup_Reply markup for the message; may be null if none.

Member Function Documentation

◆ get_id()

std::int32_t td::td_api::message::get_id ( ) const
inlinefinalvirtual

Returns identifier uniquely determining a type of the object.

Returns
this->ID.

Implements td::TlObject.

◆ store()

void td::td_api::message::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 td::TlObject.


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