public static class TdApi.Message extends TdApi.Object
Modifier and Type | Field and Description |
---|---|
java.lang.String |
authorSignature
For channel posts, optional author signature.
|
boolean |
canBeDeletedForAllUsers
True, if the message can be deleted for all users.
|
boolean |
canBeDeletedOnlyForSelf
True, if the message can be deleted only for the current user while other users will continue to see it.
|
boolean |
canBeEdited
True, if the message can be edited.
|
boolean |
canBeForwarded
True, if the message can be forwarded.
|
long |
chatId
Chat identifier.
|
static int |
CONSTRUCTOR
Identifier uniquely determining type of the object.
|
boolean |
containsUnreadMention
True, if the message contains an unread mention for the current user.
|
TdApi.MessageContent |
content
Content of the message.
|
int |
date
Point in time (Unix timestamp) when the message was sent.
|
int |
editDate
Point in time (Unix timestamp) when the message was last edited.
|
TdApi.MessageForwardInfo |
forwardInfo
Information about the initial message sender; may be null.
|
long |
id
Message identifier, unique for the chat to which the message belongs.
|
boolean |
isChannelPost
True, if the message is a channel post.
|
boolean |
isOutgoing
True, if the message is outgoing.
|
long |
mediaAlbumId
Unique identifier of an album this message belongs to.
|
TdApi.ReplyMarkup |
replyMarkup
Reply markup for the message; may be null.
|
long |
replyToMessageId
If non-zero, the identifier of the message this message is replying to; can be the identifier of a deleted message.
|
java.lang.String |
restrictionReason
If non-empty, contains a human-readable description of the reason why access to this message must be restricted.
|
TdApi.MessageSchedulingState |
schedulingState
Information about the scheduling state of the message; may be null.
|
int |
senderUserId
Identifier of the user who sent the message; 0 if unknown.
|
TdApi.MessageSendingState |
sendingState
Information about the sending state of the message; may be null.
|
int |
ttl
For self-destructing messages, the message's TTL (Time To Live), in seconds; 0 if none.
|
double |
ttlExpiresIn
Time left before the message expires, in seconds.
|
int |
viaBotUserId
If non-zero, the user identifier of the bot through which this message was sent.
|
int |
views
Number of times this message was viewed.
|
Constructor and Description |
---|
Message()
Describes a message.
|
Message(long id,
int senderUserId,
long chatId,
TdApi.MessageSendingState sendingState,
TdApi.MessageSchedulingState schedulingState,
boolean isOutgoing,
boolean canBeEdited,
boolean canBeForwarded,
boolean canBeDeletedOnlyForSelf,
boolean canBeDeletedForAllUsers,
boolean isChannelPost,
boolean containsUnreadMention,
int date,
int editDate,
TdApi.MessageForwardInfo forwardInfo,
long replyToMessageId,
int ttl,
double ttlExpiresIn,
int viaBotUserId,
java.lang.String authorSignature,
int views,
long mediaAlbumId,
java.lang.String restrictionReason,
TdApi.MessageContent content,
TdApi.ReplyMarkup replyMarkup)
Describes a message.
|
Modifier and Type | Method and Description |
---|---|
int |
getConstructor() |
toString
public long id
public int senderUserId
public long chatId
@Nullable public TdApi.MessageSendingState sendingState
@Nullable public TdApi.MessageSchedulingState schedulingState
public boolean isOutgoing
public boolean canBeEdited
public boolean canBeForwarded
public boolean canBeDeletedOnlyForSelf
public boolean canBeDeletedForAllUsers
public boolean isChannelPost
public boolean containsUnreadMention
public int date
public int editDate
@Nullable public TdApi.MessageForwardInfo forwardInfo
public long replyToMessageId
public int ttl
public double ttlExpiresIn
public int viaBotUserId
public java.lang.String authorSignature
public int views
public long mediaAlbumId
public java.lang.String restrictionReason
public TdApi.MessageContent content
@Nullable public TdApi.ReplyMarkup replyMarkup
public static final int CONSTRUCTOR
public Message()
public Message(long id, int senderUserId, long chatId, TdApi.MessageSendingState sendingState, TdApi.MessageSchedulingState schedulingState, boolean isOutgoing, boolean canBeEdited, boolean canBeForwarded, boolean canBeDeletedOnlyForSelf, boolean canBeDeletedForAllUsers, boolean isChannelPost, boolean containsUnreadMention, int date, int editDate, TdApi.MessageForwardInfo forwardInfo, long replyToMessageId, int ttl, double ttlExpiresIn, int viaBotUserId, java.lang.String authorSignature, int views, long mediaAlbumId, java.lang.String restrictionReason, TdApi.MessageContent content, TdApi.ReplyMarkup replyMarkup)
id
- Message identifier, unique for the chat to which the message belongs.senderUserId
- Identifier of the user who sent the message; 0 if unknown. Currently, it is unknown for channel posts and for channel posts automatically forwarded to discussion group.chatId
- Chat identifier.sendingState
- Information about the sending state of the message; may be null.schedulingState
- Information about the scheduling state of the message; may be null.isOutgoing
- True, if the message is outgoing.canBeEdited
- 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 client.canBeForwarded
- True, if the message can be forwarded.canBeDeletedOnlyForSelf
- True, if the message can be deleted only for the current user while other users will continue to see it.canBeDeletedForAllUsers
- True, if the message can be deleted for all users.isChannelPost
- True, if the message is a channel post. All messages to channels are channel posts, all other messages are not channel posts.containsUnreadMention
- True, if the message contains an unread mention for the current user.date
- Point in time (Unix timestamp) when the message was sent.editDate
- Point in time (Unix timestamp) when the message was last edited.forwardInfo
- Information about the initial message sender; may be null.replyToMessageId
- If non-zero, the identifier of the message this message is replying to; can be the identifier of a deleted message.ttl
- For self-destructing messages, the message's TTL (Time To Live), in seconds; 0 if none. TDLib will send updateDeleteMessages or updateMessageContent once the TTL expires.ttlExpiresIn
- Time left before the message expires, in seconds.viaBotUserId
- If non-zero, the user identifier of the bot through which this message was sent.authorSignature
- For channel posts, optional author signature.views
- Number of times this message was viewed.mediaAlbumId
- Unique identifier of an album this message belongs to. Only photos and videos can be grouped together in albums.restrictionReason
- If non-empty, contains a human-readable description of the reason why access to this message must be restricted.content
- Content of the message.replyMarkup
- Reply markup for the message; may be null.public int getConstructor()
getConstructor
in class TdApi.Object