Class TdApi.SearchSavedMessages
java.lang.Object
dev.voroby.springframework.telegram.client.TdApi.Object
dev.voroby.springframework.telegram.client.TdApi.Function<TdApi.FoundChatMessages>
dev.voroby.springframework.telegram.client.TdApi.SearchSavedMessages
- Enclosing class:
- TdApi
Searches for messages tagged by the given reaction and with the given words in the Saved Messages chat; for Telegram Premium users only. Returns the results in reverse chronological order, i.e. in order of decreasing messageId For optimal performance, the number of returned messages is chosen by TDLib and can be smaller than the specified limit.
Returns FoundChatMessages
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
Identifier uniquely determining type of the object.long
Identifier of the message starting from which messages must be fetched; use 0 to get results from the last message.int
The maximum number of messages to be returned; must be positive and can't be greater than 100.int
Specify 0 to get results from exactly the message fromMessageId or a negative offset to get the specified message and some newer messages.Query to search for.long
If not 0, only messages in the specified Saved Messages topic will be considered; pass 0 to consider all messages.Tag to search for; pass null to return all suitable messages. -
Constructor Summary
ConstructorDescriptionDefault constructor for a function, which searches for messages tagged by the given reaction and with the given words in the Saved Messages chat; for Telegram Premium users only.SearchSavedMessages
(long savedMessagesTopicId, TdApi.ReactionType tag, String query, long fromMessageId, int offset, int limit) Creates a function, which searches for messages tagged by the given reaction and with the given words in the Saved Messages chat; for Telegram Premium users only. -
Method Summary
Modifier and TypeMethodDescriptionint
Returns an identifier uniquely determining type of the object.Methods inherited from class dev.voroby.springframework.telegram.client.TdApi.Function
toString
-
Field Details
-
savedMessagesTopicId
public long savedMessagesTopicIdIf not 0, only messages in the specified Saved Messages topic will be considered; pass 0 to consider all messages. -
tag
Tag to search for; pass null to return all suitable messages. -
query
Query to search for. -
fromMessageId
public long fromMessageIdIdentifier of the message starting from which messages must be fetched; use 0 to get results from the last message. -
offset
public int offsetSpecify 0 to get results from exactly the message fromMessageId or a negative offset to get the specified message and some newer messages. -
limit
public int limitThe maximum number of messages to be returned; must be positive and can't be greater than 100. If the offset is negative, the limit must be greater than -offset. For optimal performance, the number of returned messages is chosen by TDLib and can be smaller than the specified limit. -
CONSTRUCTOR
public static final int CONSTRUCTORIdentifier uniquely determining type of the object.- See Also:
-
-
Constructor Details
-
SearchSavedMessages
public SearchSavedMessages()Default constructor for a function, which searches for messages tagged by the given reaction and with the given words in the Saved Messages chat; for Telegram Premium users only. Returns the results in reverse chronological order, i.e. in order of decreasing messageId For optimal performance, the number of returned messages is chosen by TDLib and can be smaller than the specified limit.Returns
FoundChatMessages
-
SearchSavedMessages
public SearchSavedMessages(long savedMessagesTopicId, TdApi.ReactionType tag, String query, long fromMessageId, int offset, int limit) Creates a function, which searches for messages tagged by the given reaction and with the given words in the Saved Messages chat; for Telegram Premium users only. Returns the results in reverse chronological order, i.e. in order of decreasing messageId For optimal performance, the number of returned messages is chosen by TDLib and can be smaller than the specified limit.Returns
FoundChatMessages
- Parameters:
savedMessagesTopicId
- If not 0, only messages in the specified Saved Messages topic will be considered; pass 0 to consider all messages.tag
- Tag to search for; pass null to return all suitable messages.query
- Query to search for.fromMessageId
- Identifier of the message starting from which messages must be fetched; use 0 to get results from the last message.offset
- Specify 0 to get results from exactly the message fromMessageId or a negative offset to get the specified message and some newer messages.limit
- The maximum number of messages to be returned; must be positive and can't be greater than 100. If the offset is negative, the limit must be greater than -offset. For optimal performance, the number of returned messages is chosen by TDLib and can be smaller than the specified limit.
-
-
Method Details
-
getConstructor
public int getConstructor()Description copied from class:TdApi.Object
Returns an identifier uniquely determining type of the object.- Specified by:
getConstructor
in classTdApi.Object
- Returns:
- this.CONSTRUCTOR
-