SearchChatMessages class
Searches for messages with given words in the chat. Returns the results in reverse chronological order, i.e. in order of decreasing message_id. Cannot be used in secret chats with a non-empty query (searchSecretMessages must be used instead), or without an enabled message database. For optimal performance, the number of returned messages is chosen by TDLib and can be smaller than the specified limit. A combination of query, sender_id, filter and message_thread_id search criteria is expected to be supported, only if it is required for Telegram official application implementation
- Inheritance
-
- Object
- Td
- TdFunction
- SearchChatMessages
Constructors
- SearchChatMessages({String? extra, int? client_id, int53? chat_id, string? query, MessageSender? sender_id, int53? from_message_id, int32? offset, int32? limit, SearchMessagesFilter? filter, int53? message_thread_id})
-
SearchChatMessages.fromMap(Map<
String, dynamic> map)
Properties
- chat_id ↔ int53?
-
Identifier of the chat in which to search messages
getter/setter pair
- client_id ↔ int?
-
TDLib client id; maps to the field @client_id.
getter/setter pairinherited
- extra ↔ String?
-
Matches requests with responses; maps to the field @extra.
getter/setter pairinherited
- filter ↔ SearchMessagesFilter?
-
Additional filter for messages to search; pass null to search for all messages
getter/setter pair
- from_message_id ↔ int53?
-
Identifier of the message starting from which history must be fetched; use 0 to get results from the last message
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- limit ↔ int32?
-
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
getter/setter pair
- message_thread_id ↔ int53?
-
If not 0, only messages in the specified thread will be returned; supergroups only
getter/setter pair
- offset ↔ int32?
-
Specify 0 to get results from exactly the from_message_id or a negative offset to get the specified message and some newer messages
getter/setter pair
- query ↔ string?
-
Query to search for
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- sender_id ↔ MessageSender?
-
Identifier of the sender of messages to search for; pass null to search for messages from any sender. Not supported in secret chats
getter/setter pair
- tdReturnType → String
-
The return type as String for this function.
Currently not used.
no setteroverride
- tdType → String
-
JSON object type; maps to the field @type.
no setteroverride
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
{dynamic skipNulls = true}) → String -
Serialize a Td instance to a JSON string.
If
skipNullsistruethe fields with null values are not serialized.inherited -
toMap(
{dynamic skipNulls = true}) → Map< String, dynamic> -
Create a Map from a Td instance.
override
-
toString(
{dynamic skipNulls = false}) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited